raktajs 0.1.0
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.
- package/README.md +90 -0
- package/dist/auto-import/generator.d.ts +4 -0
- package/dist/auto-import/generator.d.ts.map +1 -0
- package/dist/auto-import/index.d.ts +5 -0
- package/dist/auto-import/index.d.ts.map +1 -0
- package/dist/auto-import/index.js +153 -0
- package/dist/auto-import/index.js.map +11 -0
- package/dist/auto-import/scanner.d.ts +9 -0
- package/dist/auto-import/scanner.d.ts.map +1 -0
- package/dist/auto-import/types.d.ts +20 -0
- package/dist/auto-import/types.d.ts.map +1 -0
- package/dist/cli/build.d.ts +2 -0
- package/dist/cli/build.d.ts.map +1 -0
- package/dist/cli/dev.d.ts +2 -0
- package/dist/cli/dev.d.ts.map +1 -0
- package/dist/cli/doctor.d.ts +2 -0
- package/dist/cli/doctor.d.ts.map +1 -0
- package/dist/cli/imports.d.ts +2 -0
- package/dist/cli/imports.d.ts.map +1 -0
- package/dist/cli/index.d.ts +3 -0
- package/dist/cli/index.d.ts.map +1 -0
- package/dist/cli/make.d.ts +4 -0
- package/dist/cli/make.d.ts.map +1 -0
- package/dist/cli/rakta.d.ts +3 -0
- package/dist/cli/rakta.d.ts.map +1 -0
- package/dist/cli/rakta.js +1511 -0
- package/dist/cli/rakta.js.map +33 -0
- package/dist/cli/routes.d.ts +2 -0
- package/dist/cli/routes.d.ts.map +1 -0
- package/dist/cli/rpcTypes.d.ts +2 -0
- package/dist/cli/rpcTypes.d.ts.map +1 -0
- package/dist/cli/seo.d.ts +2 -0
- package/dist/cli/seo.d.ts.map +1 -0
- package/dist/cli/start.d.ts +2 -0
- package/dist/cli/start.d.ts.map +1 -0
- package/dist/components/Click.d.ts +11 -0
- package/dist/components/Click.d.ts.map +1 -0
- package/dist/components/Picture.d.ts +22 -0
- package/dist/components/Picture.d.ts.map +1 -0
- package/dist/components/index.d.ts +5 -0
- package/dist/components/index.d.ts.map +1 -0
- package/dist/components/index.js +1383 -0
- package/dist/components/index.js.map +15 -0
- package/dist/config/defineConfig.d.ts +64 -0
- package/dist/config/defineConfig.d.ts.map +1 -0
- package/dist/config/index.d.ts +4 -0
- package/dist/config/index.d.ts.map +1 -0
- package/dist/config/index.js +104 -0
- package/dist/config/index.js.map +11 -0
- package/dist/config/loadConfig.d.ts +4 -0
- package/dist/config/loadConfig.d.ts.map +1 -0
- package/dist/forge/build.d.ts +7 -0
- package/dist/forge/build.d.ts.map +1 -0
- package/dist/forge/devServer.d.ts +7 -0
- package/dist/forge/devServer.d.ts.map +1 -0
- package/dist/forge/index.d.ts +6 -0
- package/dist/forge/index.d.ts.map +1 -0
- package/dist/forge/index.js +579 -0
- package/dist/forge/index.js.map +17 -0
- package/dist/forge/inspect.d.ts +9 -0
- package/dist/forge/inspect.d.ts.map +1 -0
- package/dist/forge/types.d.ts +55 -0
- package/dist/forge/types.d.ts.map +1 -0
- package/dist/http/errors.d.ts +17 -0
- package/dist/http/errors.d.ts.map +1 -0
- package/dist/http/index.d.ts +4 -0
- package/dist/http/index.d.ts.map +1 -0
- package/dist/http/index.js +154 -0
- package/dist/http/index.js.map +11 -0
- package/dist/http/panturaFetch.d.ts +33 -0
- package/dist/http/panturaFetch.d.ts.map +1 -0
- package/dist/http/types.d.ts +24 -0
- package/dist/http/types.d.ts.map +1 -0
- package/dist/index.d.ts +30 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +3872 -0
- package/dist/index.js.map +50 -0
- package/dist/pwa/cache.d.ts +6 -0
- package/dist/pwa/cache.d.ts.map +1 -0
- package/dist/pwa/index.d.ts +5 -0
- package/dist/pwa/index.d.ts.map +1 -0
- package/dist/pwa/index.js +136 -0
- package/dist/pwa/index.js.map +12 -0
- package/dist/pwa/manifest.d.ts +11 -0
- package/dist/pwa/manifest.d.ts.map +1 -0
- package/dist/pwa/serviceWorker.d.ts +11 -0
- package/dist/pwa/serviceWorker.d.ts.map +1 -0
- package/dist/pwa/types.d.ts +45 -0
- package/dist/pwa/types.d.ts.map +1 -0
- package/dist/render/index.d.ts +5 -0
- package/dist/render/index.d.ts.map +1 -0
- package/dist/render/index.js +183 -0
- package/dist/render/index.js.map +11 -0
- package/dist/render/modes.d.ts +13 -0
- package/dist/render/modes.d.ts.map +1 -0
- package/dist/render/renderer.d.ts +15 -0
- package/dist/render/renderer.d.ts.map +1 -0
- package/dist/render/types.d.ts +72 -0
- package/dist/render/types.d.ts.map +1 -0
- package/dist/router/index.d.ts +5 -0
- package/dist/router/index.d.ts.map +1 -0
- package/dist/router/index.js +228 -0
- package/dist/router/index.js.map +12 -0
- package/dist/router/manifest.d.ts +6 -0
- package/dist/router/manifest.d.ts.map +1 -0
- package/dist/router/matcher.d.ts +5 -0
- package/dist/router/matcher.d.ts.map +1 -0
- package/dist/router/scanner.d.ts +6 -0
- package/dist/router/scanner.d.ts.map +1 -0
- package/dist/router/types.d.ts +45 -0
- package/dist/router/types.d.ts.map +1 -0
- package/dist/rpc/client.d.ts +24 -0
- package/dist/rpc/client.d.ts.map +1 -0
- package/dist/rpc/index.d.ts +6 -0
- package/dist/rpc/index.d.ts.map +1 -0
- package/dist/rpc/index.js +179 -0
- package/dist/rpc/index.js.map +13 -0
- package/dist/rpc/procedure.d.ts +28 -0
- package/dist/rpc/procedure.d.ts.map +1 -0
- package/dist/rpc/router.d.ts +12 -0
- package/dist/rpc/router.d.ts.map +1 -0
- package/dist/rpc/types.d.ts +48 -0
- package/dist/rpc/types.d.ts.map +1 -0
- package/dist/schema/array.d.ts +15 -0
- package/dist/schema/array.d.ts.map +1 -0
- package/dist/schema/boolean.d.ts +7 -0
- package/dist/schema/boolean.d.ts.map +1 -0
- package/dist/schema/errors.d.ts +21 -0
- package/dist/schema/errors.d.ts.map +1 -0
- package/dist/schema/index.d.ts +11 -0
- package/dist/schema/index.d.ts.map +1 -0
- package/dist/schema/index.js +393 -0
- package/dist/schema/index.js.map +16 -0
- package/dist/schema/number.d.ts +17 -0
- package/dist/schema/number.d.ts.map +1 -0
- package/dist/schema/object.d.ts +19 -0
- package/dist/schema/object.d.ts.map +1 -0
- package/dist/schema/string.d.ts +18 -0
- package/dist/schema/string.d.ts.map +1 -0
- package/dist/schema/types.d.ts +27 -0
- package/dist/schema/types.d.ts.map +1 -0
- package/dist/seo/head.d.ts +8 -0
- package/dist/seo/head.d.ts.map +1 -0
- package/dist/seo/index.d.ts +9 -0
- package/dist/seo/index.d.ts.map +1 -0
- package/dist/seo/index.js +1578 -0
- package/dist/seo/index.js.map +17 -0
- package/dist/seo/metadata.d.ts +106 -0
- package/dist/seo/metadata.d.ts.map +1 -0
- package/dist/seo/robots.d.ts +14 -0
- package/dist/seo/robots.d.ts.map +1 -0
- package/dist/seo/sitemap.d.ts +27 -0
- package/dist/seo/sitemap.d.ts.map +1 -0
- package/dist/store/createStore.d.ts +18 -0
- package/dist/store/createStore.d.ts.map +1 -0
- package/dist/store/index.d.ts +3 -0
- package/dist/store/index.d.ts.map +1 -0
- package/dist/store/index.js +925 -0
- package/dist/store/index.js.map +12 -0
- package/dist/store/types.d.ts +14 -0
- package/dist/store/types.d.ts.map +1 -0
- package/dist/tide/adapter.d.ts +8 -0
- package/dist/tide/adapter.d.ts.map +1 -0
- package/dist/tide/index.d.ts +4 -0
- package/dist/tide/index.d.ts.map +1 -0
- package/dist/tide/index.js +477 -0
- package/dist/tide/index.js.map +16 -0
- package/dist/tide/runtime.d.ts +8 -0
- package/dist/tide/runtime.d.ts.map +1 -0
- package/dist/tide/types.d.ts +40 -0
- package/dist/tide/types.d.ts.map +1 -0
- package/package.json +128 -0
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["..\\..\\..\\node_modules\\.bun\\react@19.2.7\\node_modules\\react\\cjs\\react.development.js", "..\\..\\..\\node_modules\\.bun\\react@19.2.7\\node_modules\\react\\index.js", "..\\..\\..\\node_modules\\.bun\\react@19.2.7\\node_modules\\react\\cjs\\react-jsx-dev-runtime.development.js", "..\\..\\..\\node_modules\\.bun\\react@19.2.7\\node_modules\\react\\jsx-dev-runtime.js", "..\\src\\auto-import\\generator.ts", "..\\src\\auto-import\\scanner.ts", "..\\src\\components\\Click.tsx", "..\\src\\components\\Picture.tsx", "..\\src\\config\\defineConfig.ts", "..\\src\\config\\loadConfig.ts", "..\\src\\forge\\build.ts", "..\\src\\router\\manifest.ts", "..\\src\\router\\scanner.ts", "..\\src\\forge\\devServer.ts", "..\\src\\render\\modes.ts", "..\\src\\render\\renderer.ts", "..\\src\\router\\matcher.ts", "..\\src\\forge\\inspect.ts", "..\\src\\http\\errors.ts", "..\\src\\http\\panturaFetch.ts", "..\\src\\pwa\\cache.ts", "..\\src\\pwa\\manifest.ts", "..\\src\\pwa\\serviceWorker.ts", "..\\src\\rpc\\client.ts", "..\\src\\rpc\\procedure.ts", "..\\src\\schema\\errors.ts", "..\\src\\rpc\\router.ts", "..\\src\\schema\\types.ts", "..\\src\\schema\\array.ts", "..\\src\\schema\\boolean.ts", "..\\src\\schema\\number.ts", "..\\src\\schema\\object.ts", "..\\src\\schema\\string.ts", "..\\src\\seo\\metadata.ts", "..\\src\\seo\\head.tsx", "..\\src\\seo\\robots.ts", "..\\src\\seo\\sitemap.ts", "..\\src\\store\\createStore.ts", "..\\src\\tide\\adapter.ts", "..\\src\\tide\\runtime.ts", "..\\src\\index.ts"],
|
|
4
|
+
"sourcesContent": [
|
|
5
|
+
"/**\n * @license React\n * react.development.js\n *\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n\"use strict\";\n\"production\" !== process.env.NODE_ENV &&\n (function () {\n function defineDeprecationWarning(methodName, info) {\n Object.defineProperty(Component.prototype, methodName, {\n get: function () {\n console.warn(\n \"%s(...) is deprecated in plain JavaScript React classes. %s\",\n info[0],\n info[1]\n );\n }\n });\n }\n function getIteratorFn(maybeIterable) {\n if (null === maybeIterable || \"object\" !== typeof maybeIterable)\n return null;\n maybeIterable =\n (MAYBE_ITERATOR_SYMBOL && maybeIterable[MAYBE_ITERATOR_SYMBOL]) ||\n maybeIterable[\"@@iterator\"];\n return \"function\" === typeof maybeIterable ? maybeIterable : null;\n }\n function warnNoop(publicInstance, callerName) {\n publicInstance =\n ((publicInstance = publicInstance.constructor) &&\n (publicInstance.displayName || publicInstance.name)) ||\n \"ReactClass\";\n var warningKey = publicInstance + \".\" + callerName;\n didWarnStateUpdateForUnmountedComponent[warningKey] ||\n (console.error(\n \"Can't call %s on a component that is not yet mounted. This is a no-op, but it might indicate a bug in your application. Instead, assign to `this.state` directly or define a `state = {};` class property with the desired state in the %s component.\",\n callerName,\n publicInstance\n ),\n (didWarnStateUpdateForUnmountedComponent[warningKey] = !0));\n }\n function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n this.updater = updater || ReactNoopUpdateQueue;\n }\n function ComponentDummy() {}\n function PureComponent(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n this.updater = updater || ReactNoopUpdateQueue;\n }\n function noop() {}\n function testStringCoercion(value) {\n return \"\" + value;\n }\n function checkKeyStringCoercion(value) {\n try {\n testStringCoercion(value);\n var JSCompiler_inline_result = !1;\n } catch (e) {\n JSCompiler_inline_result = !0;\n }\n if (JSCompiler_inline_result) {\n JSCompiler_inline_result = console;\n var JSCompiler_temp_const = JSCompiler_inline_result.error;\n var JSCompiler_inline_result$jscomp$0 =\n (\"function\" === typeof Symbol &&\n Symbol.toStringTag &&\n value[Symbol.toStringTag]) ||\n value.constructor.name ||\n \"Object\";\n JSCompiler_temp_const.call(\n JSCompiler_inline_result,\n \"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.\",\n JSCompiler_inline_result$jscomp$0\n );\n return testStringCoercion(value);\n }\n }\n function getComponentNameFromType(type) {\n if (null == type) return null;\n if (\"function\" === typeof type)\n return type.$$typeof === REACT_CLIENT_REFERENCE\n ? null\n : type.displayName || type.name || null;\n if (\"string\" === typeof type) return type;\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n return \"Fragment\";\n case REACT_PROFILER_TYPE:\n return \"Profiler\";\n case REACT_STRICT_MODE_TYPE:\n return \"StrictMode\";\n case REACT_SUSPENSE_TYPE:\n return \"Suspense\";\n case REACT_SUSPENSE_LIST_TYPE:\n return \"SuspenseList\";\n case REACT_ACTIVITY_TYPE:\n return \"Activity\";\n }\n if (\"object\" === typeof type)\n switch (\n (\"number\" === typeof type.tag &&\n console.error(\n \"Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue.\"\n ),\n type.$$typeof)\n ) {\n case REACT_PORTAL_TYPE:\n return \"Portal\";\n case REACT_CONTEXT_TYPE:\n return type.displayName || \"Context\";\n case REACT_CONSUMER_TYPE:\n return (type._context.displayName || \"Context\") + \".Consumer\";\n case REACT_FORWARD_REF_TYPE:\n var innerType = type.render;\n type = type.displayName;\n type ||\n ((type = innerType.displayName || innerType.name || \"\"),\n (type = \"\" !== type ? \"ForwardRef(\" + type + \")\" : \"ForwardRef\"));\n return type;\n case REACT_MEMO_TYPE:\n return (\n (innerType = type.displayName || null),\n null !== innerType\n ? innerType\n : getComponentNameFromType(type.type) || \"Memo\"\n );\n case REACT_LAZY_TYPE:\n innerType = type._payload;\n type = type._init;\n try {\n return getComponentNameFromType(type(innerType));\n } catch (x) {}\n }\n return null;\n }\n function getTaskName(type) {\n if (type === REACT_FRAGMENT_TYPE) return \"<>\";\n if (\n \"object\" === typeof type &&\n null !== type &&\n type.$$typeof === REACT_LAZY_TYPE\n )\n return \"<...>\";\n try {\n var name = getComponentNameFromType(type);\n return name ? \"<\" + name + \">\" : \"<...>\";\n } catch (x) {\n return \"<...>\";\n }\n }\n function getOwner() {\n var dispatcher = ReactSharedInternals.A;\n return null === dispatcher ? null : dispatcher.getOwner();\n }\n function UnknownOwner() {\n return Error(\"react-stack-top-frame\");\n }\n function hasValidKey(config) {\n if (hasOwnProperty.call(config, \"key\")) {\n var getter = Object.getOwnPropertyDescriptor(config, \"key\").get;\n if (getter && getter.isReactWarning) return !1;\n }\n return void 0 !== config.key;\n }\n function defineKeyPropWarningGetter(props, displayName) {\n function warnAboutAccessingKey() {\n specialPropKeyWarningShown ||\n ((specialPropKeyWarningShown = !0),\n console.error(\n \"%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)\",\n displayName\n ));\n }\n warnAboutAccessingKey.isReactWarning = !0;\n Object.defineProperty(props, \"key\", {\n get: warnAboutAccessingKey,\n configurable: !0\n });\n }\n function elementRefGetterWithDeprecationWarning() {\n var componentName = getComponentNameFromType(this.type);\n didWarnAboutElementRef[componentName] ||\n ((didWarnAboutElementRef[componentName] = !0),\n console.error(\n \"Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release.\"\n ));\n componentName = this.props.ref;\n return void 0 !== componentName ? componentName : null;\n }\n function ReactElement(type, key, props, owner, debugStack, debugTask) {\n var refProp = props.ref;\n type = {\n $$typeof: REACT_ELEMENT_TYPE,\n type: type,\n key: key,\n props: props,\n _owner: owner\n };\n null !== (void 0 !== refProp ? refProp : null)\n ? Object.defineProperty(type, \"ref\", {\n enumerable: !1,\n get: elementRefGetterWithDeprecationWarning\n })\n : Object.defineProperty(type, \"ref\", { enumerable: !1, value: null });\n type._store = {};\n Object.defineProperty(type._store, \"validated\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: 0\n });\n Object.defineProperty(type, \"_debugInfo\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: null\n });\n Object.defineProperty(type, \"_debugStack\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: debugStack\n });\n Object.defineProperty(type, \"_debugTask\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: debugTask\n });\n Object.freeze && (Object.freeze(type.props), Object.freeze(type));\n return type;\n }\n function cloneAndReplaceKey(oldElement, newKey) {\n newKey = ReactElement(\n oldElement.type,\n newKey,\n oldElement.props,\n oldElement._owner,\n oldElement._debugStack,\n oldElement._debugTask\n );\n oldElement._store &&\n (newKey._store.validated = oldElement._store.validated);\n return newKey;\n }\n function validateChildKeys(node) {\n isValidElement(node)\n ? node._store && (node._store.validated = 1)\n : \"object\" === typeof node &&\n null !== node &&\n node.$$typeof === REACT_LAZY_TYPE &&\n (\"fulfilled\" === node._payload.status\n ? isValidElement(node._payload.value) &&\n node._payload.value._store &&\n (node._payload.value._store.validated = 1)\n : node._store && (node._store.validated = 1));\n }\n function isValidElement(object) {\n return (\n \"object\" === typeof object &&\n null !== object &&\n object.$$typeof === REACT_ELEMENT_TYPE\n );\n }\n function escape(key) {\n var escaperLookup = { \"=\": \"=0\", \":\": \"=2\" };\n return (\n \"$\" +\n key.replace(/[=:]/g, function (match) {\n return escaperLookup[match];\n })\n );\n }\n function getElementKey(element, index) {\n return \"object\" === typeof element &&\n null !== element &&\n null != element.key\n ? (checkKeyStringCoercion(element.key), escape(\"\" + element.key))\n : index.toString(36);\n }\n function resolveThenable(thenable) {\n switch (thenable.status) {\n case \"fulfilled\":\n return thenable.value;\n case \"rejected\":\n throw thenable.reason;\n default:\n switch (\n (\"string\" === typeof thenable.status\n ? thenable.then(noop, noop)\n : ((thenable.status = \"pending\"),\n thenable.then(\n function (fulfilledValue) {\n \"pending\" === thenable.status &&\n ((thenable.status = \"fulfilled\"),\n (thenable.value = fulfilledValue));\n },\n function (error) {\n \"pending\" === thenable.status &&\n ((thenable.status = \"rejected\"),\n (thenable.reason = error));\n }\n )),\n thenable.status)\n ) {\n case \"fulfilled\":\n return thenable.value;\n case \"rejected\":\n throw thenable.reason;\n }\n }\n throw thenable;\n }\n function mapIntoArray(children, array, escapedPrefix, nameSoFar, callback) {\n var type = typeof children;\n if (\"undefined\" === type || \"boolean\" === type) children = null;\n var invokeCallback = !1;\n if (null === children) invokeCallback = !0;\n else\n switch (type) {\n case \"bigint\":\n case \"string\":\n case \"number\":\n invokeCallback = !0;\n break;\n case \"object\":\n switch (children.$$typeof) {\n case REACT_ELEMENT_TYPE:\n case REACT_PORTAL_TYPE:\n invokeCallback = !0;\n break;\n case REACT_LAZY_TYPE:\n return (\n (invokeCallback = children._init),\n mapIntoArray(\n invokeCallback(children._payload),\n array,\n escapedPrefix,\n nameSoFar,\n callback\n )\n );\n }\n }\n if (invokeCallback) {\n invokeCallback = children;\n callback = callback(invokeCallback);\n var childKey =\n \"\" === nameSoFar ? \".\" + getElementKey(invokeCallback, 0) : nameSoFar;\n isArrayImpl(callback)\n ? ((escapedPrefix = \"\"),\n null != childKey &&\n (escapedPrefix =\n childKey.replace(userProvidedKeyEscapeRegex, \"$&/\") + \"/\"),\n mapIntoArray(callback, array, escapedPrefix, \"\", function (c) {\n return c;\n }))\n : null != callback &&\n (isValidElement(callback) &&\n (null != callback.key &&\n ((invokeCallback && invokeCallback.key === callback.key) ||\n checkKeyStringCoercion(callback.key)),\n (escapedPrefix = cloneAndReplaceKey(\n callback,\n escapedPrefix +\n (null == callback.key ||\n (invokeCallback && invokeCallback.key === callback.key)\n ? \"\"\n : (\"\" + callback.key).replace(\n userProvidedKeyEscapeRegex,\n \"$&/\"\n ) + \"/\") +\n childKey\n )),\n \"\" !== nameSoFar &&\n null != invokeCallback &&\n isValidElement(invokeCallback) &&\n null == invokeCallback.key &&\n invokeCallback._store &&\n !invokeCallback._store.validated &&\n (escapedPrefix._store.validated = 2),\n (callback = escapedPrefix)),\n array.push(callback));\n return 1;\n }\n invokeCallback = 0;\n childKey = \"\" === nameSoFar ? \".\" : nameSoFar + \":\";\n if (isArrayImpl(children))\n for (var i = 0; i < children.length; i++)\n (nameSoFar = children[i]),\n (type = childKey + getElementKey(nameSoFar, i)),\n (invokeCallback += mapIntoArray(\n nameSoFar,\n array,\n escapedPrefix,\n type,\n callback\n ));\n else if (((i = getIteratorFn(children)), \"function\" === typeof i))\n for (\n i === children.entries &&\n (didWarnAboutMaps ||\n console.warn(\n \"Using Maps as children is not supported. Use an array of keyed ReactElements instead.\"\n ),\n (didWarnAboutMaps = !0)),\n children = i.call(children),\n i = 0;\n !(nameSoFar = children.next()).done;\n\n )\n (nameSoFar = nameSoFar.value),\n (type = childKey + getElementKey(nameSoFar, i++)),\n (invokeCallback += mapIntoArray(\n nameSoFar,\n array,\n escapedPrefix,\n type,\n callback\n ));\n else if (\"object\" === type) {\n if (\"function\" === typeof children.then)\n return mapIntoArray(\n resolveThenable(children),\n array,\n escapedPrefix,\n nameSoFar,\n callback\n );\n array = String(children);\n throw Error(\n \"Objects are not valid as a React child (found: \" +\n (\"[object Object]\" === array\n ? \"object with keys {\" + Object.keys(children).join(\", \") + \"}\"\n : array) +\n \"). If you meant to render a collection of children, use an array instead.\"\n );\n }\n return invokeCallback;\n }\n function mapChildren(children, func, context) {\n if (null == children) return children;\n var result = [],\n count = 0;\n mapIntoArray(children, result, \"\", \"\", function (child) {\n return func.call(context, child, count++);\n });\n return result;\n }\n function lazyInitializer(payload) {\n if (-1 === payload._status) {\n var ioInfo = payload._ioInfo;\n null != ioInfo && (ioInfo.start = ioInfo.end = performance.now());\n ioInfo = payload._result;\n var thenable = ioInfo();\n thenable.then(\n function (moduleObject) {\n if (0 === payload._status || -1 === payload._status) {\n payload._status = 1;\n payload._result = moduleObject;\n var _ioInfo = payload._ioInfo;\n null != _ioInfo && (_ioInfo.end = performance.now());\n void 0 === thenable.status &&\n ((thenable.status = \"fulfilled\"),\n (thenable.value = moduleObject));\n }\n },\n function (error) {\n if (0 === payload._status || -1 === payload._status) {\n payload._status = 2;\n payload._result = error;\n var _ioInfo2 = payload._ioInfo;\n null != _ioInfo2 && (_ioInfo2.end = performance.now());\n void 0 === thenable.status &&\n ((thenable.status = \"rejected\"), (thenable.reason = error));\n }\n }\n );\n ioInfo = payload._ioInfo;\n if (null != ioInfo) {\n ioInfo.value = thenable;\n var displayName = thenable.displayName;\n \"string\" === typeof displayName && (ioInfo.name = displayName);\n }\n -1 === payload._status &&\n ((payload._status = 0), (payload._result = thenable));\n }\n if (1 === payload._status)\n return (\n (ioInfo = payload._result),\n void 0 === ioInfo &&\n console.error(\n \"lazy: Expected the result of a dynamic import() call. Instead received: %s\\n\\nYour code should look like: \\n const MyComponent = lazy(() => import('./MyComponent'))\\n\\nDid you accidentally put curly braces around the import?\",\n ioInfo\n ),\n \"default\" in ioInfo ||\n console.error(\n \"lazy: Expected the result of a dynamic import() call. Instead received: %s\\n\\nYour code should look like: \\n const MyComponent = lazy(() => import('./MyComponent'))\",\n ioInfo\n ),\n ioInfo.default\n );\n throw payload._result;\n }\n function resolveDispatcher() {\n var dispatcher = ReactSharedInternals.H;\n null === dispatcher &&\n console.error(\n \"Invalid hook call. Hooks can only be called inside of the body of a function component. This could happen for one of the following reasons:\\n1. You might have mismatching versions of React and the renderer (such as React DOM)\\n2. You might be breaking the Rules of Hooks\\n3. You might have more than one copy of React in the same app\\nSee https://react.dev/link/invalid-hook-call for tips about how to debug and fix this problem.\"\n );\n return dispatcher;\n }\n function releaseAsyncTransition() {\n ReactSharedInternals.asyncTransitions--;\n }\n function enqueueTask(task) {\n if (null === enqueueTaskImpl)\n try {\n var requireString = (\"require\" + Math.random()).slice(0, 7);\n enqueueTaskImpl = (module && module[requireString]).call(\n module,\n \"timers\"\n ).setImmediate;\n } catch (_err) {\n enqueueTaskImpl = function (callback) {\n !1 === didWarnAboutMessageChannel &&\n ((didWarnAboutMessageChannel = !0),\n \"undefined\" === typeof MessageChannel &&\n console.error(\n \"This browser does not have a MessageChannel implementation, so enqueuing tasks via await act(async () => ...) will fail. Please file an issue at https://github.com/facebook/react/issues if you encounter this warning.\"\n ));\n var channel = new MessageChannel();\n channel.port1.onmessage = callback;\n channel.port2.postMessage(void 0);\n };\n }\n return enqueueTaskImpl(task);\n }\n function aggregateErrors(errors) {\n return 1 < errors.length && \"function\" === typeof AggregateError\n ? new AggregateError(errors)\n : errors[0];\n }\n function popActScope(prevActQueue, prevActScopeDepth) {\n prevActScopeDepth !== actScopeDepth - 1 &&\n console.error(\n \"You seem to have overlapping act() calls, this is not supported. Be sure to await previous act() calls before making a new one. \"\n );\n actScopeDepth = prevActScopeDepth;\n }\n function recursivelyFlushAsyncActWork(returnValue, resolve, reject) {\n var queue = ReactSharedInternals.actQueue;\n if (null !== queue)\n if (0 !== queue.length)\n try {\n flushActQueue(queue);\n enqueueTask(function () {\n return recursivelyFlushAsyncActWork(returnValue, resolve, reject);\n });\n return;\n } catch (error) {\n ReactSharedInternals.thrownErrors.push(error);\n }\n else ReactSharedInternals.actQueue = null;\n 0 < ReactSharedInternals.thrownErrors.length\n ? ((queue = aggregateErrors(ReactSharedInternals.thrownErrors)),\n (ReactSharedInternals.thrownErrors.length = 0),\n reject(queue))\n : resolve(returnValue);\n }\n function flushActQueue(queue) {\n if (!isFlushing) {\n isFlushing = !0;\n var i = 0;\n try {\n for (; i < queue.length; i++) {\n var callback = queue[i];\n do {\n ReactSharedInternals.didUsePromise = !1;\n var continuation = callback(!1);\n if (null !== continuation) {\n if (ReactSharedInternals.didUsePromise) {\n queue[i] = callback;\n queue.splice(0, i);\n return;\n }\n callback = continuation;\n } else break;\n } while (1);\n }\n queue.length = 0;\n } catch (error) {\n queue.splice(0, i + 1), ReactSharedInternals.thrownErrors.push(error);\n } finally {\n isFlushing = !1;\n }\n }\n }\n \"undefined\" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&\n \"function\" ===\n typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart &&\n __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());\n var REACT_ELEMENT_TYPE = Symbol.for(\"react.transitional.element\"),\n REACT_PORTAL_TYPE = Symbol.for(\"react.portal\"),\n REACT_FRAGMENT_TYPE = Symbol.for(\"react.fragment\"),\n REACT_STRICT_MODE_TYPE = Symbol.for(\"react.strict_mode\"),\n REACT_PROFILER_TYPE = Symbol.for(\"react.profiler\"),\n REACT_CONSUMER_TYPE = Symbol.for(\"react.consumer\"),\n REACT_CONTEXT_TYPE = Symbol.for(\"react.context\"),\n REACT_FORWARD_REF_TYPE = Symbol.for(\"react.forward_ref\"),\n REACT_SUSPENSE_TYPE = Symbol.for(\"react.suspense\"),\n REACT_SUSPENSE_LIST_TYPE = Symbol.for(\"react.suspense_list\"),\n REACT_MEMO_TYPE = Symbol.for(\"react.memo\"),\n REACT_LAZY_TYPE = Symbol.for(\"react.lazy\"),\n REACT_ACTIVITY_TYPE = Symbol.for(\"react.activity\"),\n MAYBE_ITERATOR_SYMBOL = Symbol.iterator,\n didWarnStateUpdateForUnmountedComponent = {},\n ReactNoopUpdateQueue = {\n isMounted: function () {\n return !1;\n },\n enqueueForceUpdate: function (publicInstance) {\n warnNoop(publicInstance, \"forceUpdate\");\n },\n enqueueReplaceState: function (publicInstance) {\n warnNoop(publicInstance, \"replaceState\");\n },\n enqueueSetState: function (publicInstance) {\n warnNoop(publicInstance, \"setState\");\n }\n },\n assign = Object.assign,\n emptyObject = {};\n Object.freeze(emptyObject);\n Component.prototype.isReactComponent = {};\n Component.prototype.setState = function (partialState, callback) {\n if (\n \"object\" !== typeof partialState &&\n \"function\" !== typeof partialState &&\n null != partialState\n )\n throw Error(\n \"takes an object of state variables to update or a function which returns an object of state variables.\"\n );\n this.updater.enqueueSetState(this, partialState, callback, \"setState\");\n };\n Component.prototype.forceUpdate = function (callback) {\n this.updater.enqueueForceUpdate(this, callback, \"forceUpdate\");\n };\n var deprecatedAPIs = {\n isMounted: [\n \"isMounted\",\n \"Instead, make sure to clean up subscriptions and pending requests in componentWillUnmount to prevent memory leaks.\"\n ],\n replaceState: [\n \"replaceState\",\n \"Refactor your code to use setState instead (see https://github.com/facebook/react/issues/3236).\"\n ]\n };\n for (fnName in deprecatedAPIs)\n deprecatedAPIs.hasOwnProperty(fnName) &&\n defineDeprecationWarning(fnName, deprecatedAPIs[fnName]);\n ComponentDummy.prototype = Component.prototype;\n deprecatedAPIs = PureComponent.prototype = new ComponentDummy();\n deprecatedAPIs.constructor = PureComponent;\n assign(deprecatedAPIs, Component.prototype);\n deprecatedAPIs.isPureReactComponent = !0;\n var isArrayImpl = Array.isArray,\n REACT_CLIENT_REFERENCE = Symbol.for(\"react.client.reference\"),\n ReactSharedInternals = {\n H: null,\n A: null,\n T: null,\n S: null,\n actQueue: null,\n asyncTransitions: 0,\n isBatchingLegacy: !1,\n didScheduleLegacyUpdate: !1,\n didUsePromise: !1,\n thrownErrors: [],\n getCurrentStack: null,\n recentlyCreatedOwnerStacks: 0\n },\n hasOwnProperty = Object.prototype.hasOwnProperty,\n createTask = console.createTask\n ? console.createTask\n : function () {\n return null;\n };\n deprecatedAPIs = {\n react_stack_bottom_frame: function (callStackForError) {\n return callStackForError();\n }\n };\n var specialPropKeyWarningShown, didWarnAboutOldJSXRuntime;\n var didWarnAboutElementRef = {};\n var unknownOwnerDebugStack = deprecatedAPIs.react_stack_bottom_frame.bind(\n deprecatedAPIs,\n UnknownOwner\n )();\n var unknownOwnerDebugTask = createTask(getTaskName(UnknownOwner));\n var didWarnAboutMaps = !1,\n userProvidedKeyEscapeRegex = /\\/+/g,\n reportGlobalError =\n \"function\" === typeof reportError\n ? reportError\n : function (error) {\n if (\n \"object\" === typeof window &&\n \"function\" === typeof window.ErrorEvent\n ) {\n var event = new window.ErrorEvent(\"error\", {\n bubbles: !0,\n cancelable: !0,\n message:\n \"object\" === typeof error &&\n null !== error &&\n \"string\" === typeof error.message\n ? String(error.message)\n : String(error),\n error: error\n });\n if (!window.dispatchEvent(event)) return;\n } else if (\n \"object\" === typeof process &&\n \"function\" === typeof process.emit\n ) {\n process.emit(\"uncaughtException\", error);\n return;\n }\n console.error(error);\n },\n didWarnAboutMessageChannel = !1,\n enqueueTaskImpl = null,\n actScopeDepth = 0,\n didWarnNoAwaitAct = !1,\n isFlushing = !1,\n queueSeveralMicrotasks =\n \"function\" === typeof queueMicrotask\n ? function (callback) {\n queueMicrotask(function () {\n return queueMicrotask(callback);\n });\n }\n : enqueueTask;\n deprecatedAPIs = Object.freeze({\n __proto__: null,\n c: function (size) {\n return resolveDispatcher().useMemoCache(size);\n }\n });\n var fnName = {\n map: mapChildren,\n forEach: function (children, forEachFunc, forEachContext) {\n mapChildren(\n children,\n function () {\n forEachFunc.apply(this, arguments);\n },\n forEachContext\n );\n },\n count: function (children) {\n var n = 0;\n mapChildren(children, function () {\n n++;\n });\n return n;\n },\n toArray: function (children) {\n return (\n mapChildren(children, function (child) {\n return child;\n }) || []\n );\n },\n only: function (children) {\n if (!isValidElement(children))\n throw Error(\n \"React.Children.only expected to receive a single React element child.\"\n );\n return children;\n }\n };\n exports.Activity = REACT_ACTIVITY_TYPE;\n exports.Children = fnName;\n exports.Component = Component;\n exports.Fragment = REACT_FRAGMENT_TYPE;\n exports.Profiler = REACT_PROFILER_TYPE;\n exports.PureComponent = PureComponent;\n exports.StrictMode = REACT_STRICT_MODE_TYPE;\n exports.Suspense = REACT_SUSPENSE_TYPE;\n exports.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE =\n ReactSharedInternals;\n exports.__COMPILER_RUNTIME = deprecatedAPIs;\n exports.act = function (callback) {\n var prevActQueue = ReactSharedInternals.actQueue,\n prevActScopeDepth = actScopeDepth;\n actScopeDepth++;\n var queue = (ReactSharedInternals.actQueue =\n null !== prevActQueue ? prevActQueue : []),\n didAwaitActCall = !1;\n try {\n var result = callback();\n } catch (error) {\n ReactSharedInternals.thrownErrors.push(error);\n }\n if (0 < ReactSharedInternals.thrownErrors.length)\n throw (\n (popActScope(prevActQueue, prevActScopeDepth),\n (callback = aggregateErrors(ReactSharedInternals.thrownErrors)),\n (ReactSharedInternals.thrownErrors.length = 0),\n callback)\n );\n if (\n null !== result &&\n \"object\" === typeof result &&\n \"function\" === typeof result.then\n ) {\n var thenable = result;\n queueSeveralMicrotasks(function () {\n didAwaitActCall ||\n didWarnNoAwaitAct ||\n ((didWarnNoAwaitAct = !0),\n console.error(\n \"You called act(async () => ...) without await. This could lead to unexpected testing behaviour, interleaving multiple act calls and mixing their scopes. You should - await act(async () => ...);\"\n ));\n });\n return {\n then: function (resolve, reject) {\n didAwaitActCall = !0;\n thenable.then(\n function (returnValue) {\n popActScope(prevActQueue, prevActScopeDepth);\n if (0 === prevActScopeDepth) {\n try {\n flushActQueue(queue),\n enqueueTask(function () {\n return recursivelyFlushAsyncActWork(\n returnValue,\n resolve,\n reject\n );\n });\n } catch (error$0) {\n ReactSharedInternals.thrownErrors.push(error$0);\n }\n if (0 < ReactSharedInternals.thrownErrors.length) {\n var _thrownError = aggregateErrors(\n ReactSharedInternals.thrownErrors\n );\n ReactSharedInternals.thrownErrors.length = 0;\n reject(_thrownError);\n }\n } else resolve(returnValue);\n },\n function (error) {\n popActScope(prevActQueue, prevActScopeDepth);\n 0 < ReactSharedInternals.thrownErrors.length\n ? ((error = aggregateErrors(\n ReactSharedInternals.thrownErrors\n )),\n (ReactSharedInternals.thrownErrors.length = 0),\n reject(error))\n : reject(error);\n }\n );\n }\n };\n }\n var returnValue$jscomp$0 = result;\n popActScope(prevActQueue, prevActScopeDepth);\n 0 === prevActScopeDepth &&\n (flushActQueue(queue),\n 0 !== queue.length &&\n queueSeveralMicrotasks(function () {\n didAwaitActCall ||\n didWarnNoAwaitAct ||\n ((didWarnNoAwaitAct = !0),\n console.error(\n \"A component suspended inside an `act` scope, but the `act` call was not awaited. When testing React components that depend on asynchronous data, you must await the result:\\n\\nawait act(() => ...)\"\n ));\n }),\n (ReactSharedInternals.actQueue = null));\n if (0 < ReactSharedInternals.thrownErrors.length)\n throw (\n ((callback = aggregateErrors(ReactSharedInternals.thrownErrors)),\n (ReactSharedInternals.thrownErrors.length = 0),\n callback)\n );\n return {\n then: function (resolve, reject) {\n didAwaitActCall = !0;\n 0 === prevActScopeDepth\n ? ((ReactSharedInternals.actQueue = queue),\n enqueueTask(function () {\n return recursivelyFlushAsyncActWork(\n returnValue$jscomp$0,\n resolve,\n reject\n );\n }))\n : resolve(returnValue$jscomp$0);\n }\n };\n };\n exports.cache = function (fn) {\n return function () {\n return fn.apply(null, arguments);\n };\n };\n exports.cacheSignal = function () {\n return null;\n };\n exports.captureOwnerStack = function () {\n var getCurrentStack = ReactSharedInternals.getCurrentStack;\n return null === getCurrentStack ? null : getCurrentStack();\n };\n exports.cloneElement = function (element, config, children) {\n if (null === element || void 0 === element)\n throw Error(\n \"The argument must be a React element, but you passed \" +\n element +\n \".\"\n );\n var props = assign({}, element.props),\n key = element.key,\n owner = element._owner;\n if (null != config) {\n var JSCompiler_inline_result;\n a: {\n if (\n hasOwnProperty.call(config, \"ref\") &&\n (JSCompiler_inline_result = Object.getOwnPropertyDescriptor(\n config,\n \"ref\"\n ).get) &&\n JSCompiler_inline_result.isReactWarning\n ) {\n JSCompiler_inline_result = !1;\n break a;\n }\n JSCompiler_inline_result = void 0 !== config.ref;\n }\n JSCompiler_inline_result && (owner = getOwner());\n hasValidKey(config) &&\n (checkKeyStringCoercion(config.key), (key = \"\" + config.key));\n for (propName in config)\n !hasOwnProperty.call(config, propName) ||\n \"key\" === propName ||\n \"__self\" === propName ||\n \"__source\" === propName ||\n (\"ref\" === propName && void 0 === config.ref) ||\n (props[propName] = config[propName]);\n }\n var propName = arguments.length - 2;\n if (1 === propName) props.children = children;\n else if (1 < propName) {\n JSCompiler_inline_result = Array(propName);\n for (var i = 0; i < propName; i++)\n JSCompiler_inline_result[i] = arguments[i + 2];\n props.children = JSCompiler_inline_result;\n }\n props = ReactElement(\n element.type,\n key,\n props,\n owner,\n element._debugStack,\n element._debugTask\n );\n for (key = 2; key < arguments.length; key++)\n validateChildKeys(arguments[key]);\n return props;\n };\n exports.createContext = function (defaultValue) {\n defaultValue = {\n $$typeof: REACT_CONTEXT_TYPE,\n _currentValue: defaultValue,\n _currentValue2: defaultValue,\n _threadCount: 0,\n Provider: null,\n Consumer: null\n };\n defaultValue.Provider = defaultValue;\n defaultValue.Consumer = {\n $$typeof: REACT_CONSUMER_TYPE,\n _context: defaultValue\n };\n defaultValue._currentRenderer = null;\n defaultValue._currentRenderer2 = null;\n return defaultValue;\n };\n exports.createElement = function (type, config, children) {\n for (var i = 2; i < arguments.length; i++)\n validateChildKeys(arguments[i]);\n i = {};\n var key = null;\n if (null != config)\n for (propName in (didWarnAboutOldJSXRuntime ||\n !(\"__self\" in config) ||\n \"key\" in config ||\n ((didWarnAboutOldJSXRuntime = !0),\n console.warn(\n \"Your app (or one of its dependencies) is using an outdated JSX transform. Update to the modern JSX transform for faster performance: https://react.dev/link/new-jsx-transform\"\n )),\n hasValidKey(config) &&\n (checkKeyStringCoercion(config.key), (key = \"\" + config.key)),\n config))\n hasOwnProperty.call(config, propName) &&\n \"key\" !== propName &&\n \"__self\" !== propName &&\n \"__source\" !== propName &&\n (i[propName] = config[propName]);\n var childrenLength = arguments.length - 2;\n if (1 === childrenLength) i.children = children;\n else if (1 < childrenLength) {\n for (\n var childArray = Array(childrenLength), _i = 0;\n _i < childrenLength;\n _i++\n )\n childArray[_i] = arguments[_i + 2];\n Object.freeze && Object.freeze(childArray);\n i.children = childArray;\n }\n if (type && type.defaultProps)\n for (propName in ((childrenLength = type.defaultProps), childrenLength))\n void 0 === i[propName] && (i[propName] = childrenLength[propName]);\n key &&\n defineKeyPropWarningGetter(\n i,\n \"function\" === typeof type\n ? type.displayName || type.name || \"Unknown\"\n : type\n );\n var propName = 1e4 > ReactSharedInternals.recentlyCreatedOwnerStacks++;\n return ReactElement(\n type,\n key,\n i,\n getOwner(),\n propName ? Error(\"react-stack-top-frame\") : unknownOwnerDebugStack,\n propName ? createTask(getTaskName(type)) : unknownOwnerDebugTask\n );\n };\n exports.createRef = function () {\n var refObject = { current: null };\n Object.seal(refObject);\n return refObject;\n };\n exports.forwardRef = function (render) {\n null != render && render.$$typeof === REACT_MEMO_TYPE\n ? console.error(\n \"forwardRef requires a render function but received a `memo` component. Instead of forwardRef(memo(...)), use memo(forwardRef(...)).\"\n )\n : \"function\" !== typeof render\n ? console.error(\n \"forwardRef requires a render function but was given %s.\",\n null === render ? \"null\" : typeof render\n )\n : 0 !== render.length &&\n 2 !== render.length &&\n console.error(\n \"forwardRef render functions accept exactly two parameters: props and ref. %s\",\n 1 === render.length\n ? \"Did you forget to use the ref parameter?\"\n : \"Any additional parameter will be undefined.\"\n );\n null != render &&\n null != render.defaultProps &&\n console.error(\n \"forwardRef render functions do not support defaultProps. Did you accidentally pass a React component?\"\n );\n var elementType = { $$typeof: REACT_FORWARD_REF_TYPE, render: render },\n ownName;\n Object.defineProperty(elementType, \"displayName\", {\n enumerable: !1,\n configurable: !0,\n get: function () {\n return ownName;\n },\n set: function (name) {\n ownName = name;\n render.name ||\n render.displayName ||\n (Object.defineProperty(render, \"name\", { value: name }),\n (render.displayName = name));\n }\n });\n return elementType;\n };\n exports.isValidElement = isValidElement;\n exports.lazy = function (ctor) {\n ctor = { _status: -1, _result: ctor };\n var lazyType = {\n $$typeof: REACT_LAZY_TYPE,\n _payload: ctor,\n _init: lazyInitializer\n },\n ioInfo = {\n name: \"lazy\",\n start: -1,\n end: -1,\n value: null,\n owner: null,\n debugStack: Error(\"react-stack-top-frame\"),\n debugTask: console.createTask ? console.createTask(\"lazy()\") : null\n };\n ctor._ioInfo = ioInfo;\n lazyType._debugInfo = [{ awaited: ioInfo }];\n return lazyType;\n };\n exports.memo = function (type, compare) {\n null == type &&\n console.error(\n \"memo: The first argument must be a component. Instead received: %s\",\n null === type ? \"null\" : typeof type\n );\n compare = {\n $$typeof: REACT_MEMO_TYPE,\n type: type,\n compare: void 0 === compare ? null : compare\n };\n var ownName;\n Object.defineProperty(compare, \"displayName\", {\n enumerable: !1,\n configurable: !0,\n get: function () {\n return ownName;\n },\n set: function (name) {\n ownName = name;\n type.name ||\n type.displayName ||\n (Object.defineProperty(type, \"name\", { value: name }),\n (type.displayName = name));\n }\n });\n return compare;\n };\n exports.startTransition = function (scope) {\n var prevTransition = ReactSharedInternals.T,\n currentTransition = {};\n currentTransition._updatedFibers = new Set();\n ReactSharedInternals.T = currentTransition;\n try {\n var returnValue = scope(),\n onStartTransitionFinish = ReactSharedInternals.S;\n null !== onStartTransitionFinish &&\n onStartTransitionFinish(currentTransition, returnValue);\n \"object\" === typeof returnValue &&\n null !== returnValue &&\n \"function\" === typeof returnValue.then &&\n (ReactSharedInternals.asyncTransitions++,\n returnValue.then(releaseAsyncTransition, releaseAsyncTransition),\n returnValue.then(noop, reportGlobalError));\n } catch (error) {\n reportGlobalError(error);\n } finally {\n null === prevTransition &&\n currentTransition._updatedFibers &&\n ((scope = currentTransition._updatedFibers.size),\n currentTransition._updatedFibers.clear(),\n 10 < scope &&\n console.warn(\n \"Detected a large number of updates inside startTransition. If this is due to a subscription please re-write it to use React provided hooks. Otherwise concurrent mode guarantees are off the table.\"\n )),\n null !== prevTransition &&\n null !== currentTransition.types &&\n (null !== prevTransition.types &&\n prevTransition.types !== currentTransition.types &&\n console.error(\n \"We expected inner Transitions to have transferred the outer types set and that you cannot add to the outer Transition while inside the inner.This is a bug in React.\"\n ),\n (prevTransition.types = currentTransition.types)),\n (ReactSharedInternals.T = prevTransition);\n }\n };\n exports.unstable_useCacheRefresh = function () {\n return resolveDispatcher().useCacheRefresh();\n };\n exports.use = function (usable) {\n return resolveDispatcher().use(usable);\n };\n exports.useActionState = function (action, initialState, permalink) {\n return resolveDispatcher().useActionState(\n action,\n initialState,\n permalink\n );\n };\n exports.useCallback = function (callback, deps) {\n return resolveDispatcher().useCallback(callback, deps);\n };\n exports.useContext = function (Context) {\n var dispatcher = resolveDispatcher();\n Context.$$typeof === REACT_CONSUMER_TYPE &&\n console.error(\n \"Calling useContext(Context.Consumer) is not supported and will cause bugs. Did you mean to call useContext(Context) instead?\"\n );\n return dispatcher.useContext(Context);\n };\n exports.useDebugValue = function (value, formatterFn) {\n return resolveDispatcher().useDebugValue(value, formatterFn);\n };\n exports.useDeferredValue = function (value, initialValue) {\n return resolveDispatcher().useDeferredValue(value, initialValue);\n };\n exports.useEffect = function (create, deps) {\n null == create &&\n console.warn(\n \"React Hook useEffect requires an effect callback. Did you forget to pass a callback to the hook?\"\n );\n return resolveDispatcher().useEffect(create, deps);\n };\n exports.useEffectEvent = function (callback) {\n return resolveDispatcher().useEffectEvent(callback);\n };\n exports.useId = function () {\n return resolveDispatcher().useId();\n };\n exports.useImperativeHandle = function (ref, create, deps) {\n return resolveDispatcher().useImperativeHandle(ref, create, deps);\n };\n exports.useInsertionEffect = function (create, deps) {\n null == create &&\n console.warn(\n \"React Hook useInsertionEffect requires an effect callback. Did you forget to pass a callback to the hook?\"\n );\n return resolveDispatcher().useInsertionEffect(create, deps);\n };\n exports.useLayoutEffect = function (create, deps) {\n null == create &&\n console.warn(\n \"React Hook useLayoutEffect requires an effect callback. Did you forget to pass a callback to the hook?\"\n );\n return resolveDispatcher().useLayoutEffect(create, deps);\n };\n exports.useMemo = function (create, deps) {\n return resolveDispatcher().useMemo(create, deps);\n };\n exports.useOptimistic = function (passthrough, reducer) {\n return resolveDispatcher().useOptimistic(passthrough, reducer);\n };\n exports.useReducer = function (reducer, initialArg, init) {\n return resolveDispatcher().useReducer(reducer, initialArg, init);\n };\n exports.useRef = function (initialValue) {\n return resolveDispatcher().useRef(initialValue);\n };\n exports.useState = function (initialState) {\n return resolveDispatcher().useState(initialState);\n };\n exports.useSyncExternalStore = function (\n subscribe,\n getSnapshot,\n getServerSnapshot\n ) {\n return resolveDispatcher().useSyncExternalStore(\n subscribe,\n getSnapshot,\n getServerSnapshot\n );\n };\n exports.useTransition = function () {\n return resolveDispatcher().useTransition();\n };\n exports.version = \"19.2.7\";\n \"undefined\" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&\n \"function\" ===\n typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&\n __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error());\n })();\n",
|
|
6
|
+
"'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react.production.js');\n} else {\n module.exports = require('./cjs/react.development.js');\n}\n",
|
|
7
|
+
"/**\n * @license React\n * react-jsx-dev-runtime.development.js\n *\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n\"use strict\";\n\"production\" !== process.env.NODE_ENV &&\n (function () {\n function getComponentNameFromType(type) {\n if (null == type) return null;\n if (\"function\" === typeof type)\n return type.$$typeof === REACT_CLIENT_REFERENCE\n ? null\n : type.displayName || type.name || null;\n if (\"string\" === typeof type) return type;\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n return \"Fragment\";\n case REACT_PROFILER_TYPE:\n return \"Profiler\";\n case REACT_STRICT_MODE_TYPE:\n return \"StrictMode\";\n case REACT_SUSPENSE_TYPE:\n return \"Suspense\";\n case REACT_SUSPENSE_LIST_TYPE:\n return \"SuspenseList\";\n case REACT_ACTIVITY_TYPE:\n return \"Activity\";\n }\n if (\"object\" === typeof type)\n switch (\n (\"number\" === typeof type.tag &&\n console.error(\n \"Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue.\"\n ),\n type.$$typeof)\n ) {\n case REACT_PORTAL_TYPE:\n return \"Portal\";\n case REACT_CONTEXT_TYPE:\n return type.displayName || \"Context\";\n case REACT_CONSUMER_TYPE:\n return (type._context.displayName || \"Context\") + \".Consumer\";\n case REACT_FORWARD_REF_TYPE:\n var innerType = type.render;\n type = type.displayName;\n type ||\n ((type = innerType.displayName || innerType.name || \"\"),\n (type = \"\" !== type ? \"ForwardRef(\" + type + \")\" : \"ForwardRef\"));\n return type;\n case REACT_MEMO_TYPE:\n return (\n (innerType = type.displayName || null),\n null !== innerType\n ? innerType\n : getComponentNameFromType(type.type) || \"Memo\"\n );\n case REACT_LAZY_TYPE:\n innerType = type._payload;\n type = type._init;\n try {\n return getComponentNameFromType(type(innerType));\n } catch (x) {}\n }\n return null;\n }\n function testStringCoercion(value) {\n return \"\" + value;\n }\n function checkKeyStringCoercion(value) {\n try {\n testStringCoercion(value);\n var JSCompiler_inline_result = !1;\n } catch (e) {\n JSCompiler_inline_result = !0;\n }\n if (JSCompiler_inline_result) {\n JSCompiler_inline_result = console;\n var JSCompiler_temp_const = JSCompiler_inline_result.error;\n var JSCompiler_inline_result$jscomp$0 =\n (\"function\" === typeof Symbol &&\n Symbol.toStringTag &&\n value[Symbol.toStringTag]) ||\n value.constructor.name ||\n \"Object\";\n JSCompiler_temp_const.call(\n JSCompiler_inline_result,\n \"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.\",\n JSCompiler_inline_result$jscomp$0\n );\n return testStringCoercion(value);\n }\n }\n function getTaskName(type) {\n if (type === REACT_FRAGMENT_TYPE) return \"<>\";\n if (\n \"object\" === typeof type &&\n null !== type &&\n type.$$typeof === REACT_LAZY_TYPE\n )\n return \"<...>\";\n try {\n var name = getComponentNameFromType(type);\n return name ? \"<\" + name + \">\" : \"<...>\";\n } catch (x) {\n return \"<...>\";\n }\n }\n function getOwner() {\n var dispatcher = ReactSharedInternals.A;\n return null === dispatcher ? null : dispatcher.getOwner();\n }\n function UnknownOwner() {\n return Error(\"react-stack-top-frame\");\n }\n function hasValidKey(config) {\n if (hasOwnProperty.call(config, \"key\")) {\n var getter = Object.getOwnPropertyDescriptor(config, \"key\").get;\n if (getter && getter.isReactWarning) return !1;\n }\n return void 0 !== config.key;\n }\n function defineKeyPropWarningGetter(props, displayName) {\n function warnAboutAccessingKey() {\n specialPropKeyWarningShown ||\n ((specialPropKeyWarningShown = !0),\n console.error(\n \"%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)\",\n displayName\n ));\n }\n warnAboutAccessingKey.isReactWarning = !0;\n Object.defineProperty(props, \"key\", {\n get: warnAboutAccessingKey,\n configurable: !0\n });\n }\n function elementRefGetterWithDeprecationWarning() {\n var componentName = getComponentNameFromType(this.type);\n didWarnAboutElementRef[componentName] ||\n ((didWarnAboutElementRef[componentName] = !0),\n console.error(\n \"Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release.\"\n ));\n componentName = this.props.ref;\n return void 0 !== componentName ? componentName : null;\n }\n function ReactElement(type, key, props, owner, debugStack, debugTask) {\n var refProp = props.ref;\n type = {\n $$typeof: REACT_ELEMENT_TYPE,\n type: type,\n key: key,\n props: props,\n _owner: owner\n };\n null !== (void 0 !== refProp ? refProp : null)\n ? Object.defineProperty(type, \"ref\", {\n enumerable: !1,\n get: elementRefGetterWithDeprecationWarning\n })\n : Object.defineProperty(type, \"ref\", { enumerable: !1, value: null });\n type._store = {};\n Object.defineProperty(type._store, \"validated\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: 0\n });\n Object.defineProperty(type, \"_debugInfo\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: null\n });\n Object.defineProperty(type, \"_debugStack\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: debugStack\n });\n Object.defineProperty(type, \"_debugTask\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: debugTask\n });\n Object.freeze && (Object.freeze(type.props), Object.freeze(type));\n return type;\n }\n function jsxDEVImpl(\n type,\n config,\n maybeKey,\n isStaticChildren,\n debugStack,\n debugTask\n ) {\n var children = config.children;\n if (void 0 !== children)\n if (isStaticChildren)\n if (isArrayImpl(children)) {\n for (\n isStaticChildren = 0;\n isStaticChildren < children.length;\n isStaticChildren++\n )\n validateChildKeys(children[isStaticChildren]);\n Object.freeze && Object.freeze(children);\n } else\n console.error(\n \"React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.\"\n );\n else validateChildKeys(children);\n if (hasOwnProperty.call(config, \"key\")) {\n children = getComponentNameFromType(type);\n var keys = Object.keys(config).filter(function (k) {\n return \"key\" !== k;\n });\n isStaticChildren =\n 0 < keys.length\n ? \"{key: someKey, \" + keys.join(\": ..., \") + \": ...}\"\n : \"{key: someKey}\";\n didWarnAboutKeySpread[children + isStaticChildren] ||\n ((keys =\n 0 < keys.length ? \"{\" + keys.join(\": ..., \") + \": ...}\" : \"{}\"),\n console.error(\n 'A props object containing a \"key\" prop is being spread into JSX:\\n let props = %s;\\n <%s {...props} />\\nReact keys must be passed directly to JSX without using spread:\\n let props = %s;\\n <%s key={someKey} {...props} />',\n isStaticChildren,\n children,\n keys,\n children\n ),\n (didWarnAboutKeySpread[children + isStaticChildren] = !0));\n }\n children = null;\n void 0 !== maybeKey &&\n (checkKeyStringCoercion(maybeKey), (children = \"\" + maybeKey));\n hasValidKey(config) &&\n (checkKeyStringCoercion(config.key), (children = \"\" + config.key));\n if (\"key\" in config) {\n maybeKey = {};\n for (var propName in config)\n \"key\" !== propName && (maybeKey[propName] = config[propName]);\n } else maybeKey = config;\n children &&\n defineKeyPropWarningGetter(\n maybeKey,\n \"function\" === typeof type\n ? type.displayName || type.name || \"Unknown\"\n : type\n );\n return ReactElement(\n type,\n children,\n maybeKey,\n getOwner(),\n debugStack,\n debugTask\n );\n }\n function validateChildKeys(node) {\n isValidElement(node)\n ? node._store && (node._store.validated = 1)\n : \"object\" === typeof node &&\n null !== node &&\n node.$$typeof === REACT_LAZY_TYPE &&\n (\"fulfilled\" === node._payload.status\n ? isValidElement(node._payload.value) &&\n node._payload.value._store &&\n (node._payload.value._store.validated = 1)\n : node._store && (node._store.validated = 1));\n }\n function isValidElement(object) {\n return (\n \"object\" === typeof object &&\n null !== object &&\n object.$$typeof === REACT_ELEMENT_TYPE\n );\n }\n var React = require(\"react\"),\n REACT_ELEMENT_TYPE = Symbol.for(\"react.transitional.element\"),\n REACT_PORTAL_TYPE = Symbol.for(\"react.portal\"),\n REACT_FRAGMENT_TYPE = Symbol.for(\"react.fragment\"),\n REACT_STRICT_MODE_TYPE = Symbol.for(\"react.strict_mode\"),\n REACT_PROFILER_TYPE = Symbol.for(\"react.profiler\"),\n REACT_CONSUMER_TYPE = Symbol.for(\"react.consumer\"),\n REACT_CONTEXT_TYPE = Symbol.for(\"react.context\"),\n REACT_FORWARD_REF_TYPE = Symbol.for(\"react.forward_ref\"),\n REACT_SUSPENSE_TYPE = Symbol.for(\"react.suspense\"),\n REACT_SUSPENSE_LIST_TYPE = Symbol.for(\"react.suspense_list\"),\n REACT_MEMO_TYPE = Symbol.for(\"react.memo\"),\n REACT_LAZY_TYPE = Symbol.for(\"react.lazy\"),\n REACT_ACTIVITY_TYPE = Symbol.for(\"react.activity\"),\n REACT_CLIENT_REFERENCE = Symbol.for(\"react.client.reference\"),\n ReactSharedInternals =\n React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,\n hasOwnProperty = Object.prototype.hasOwnProperty,\n isArrayImpl = Array.isArray,\n createTask = console.createTask\n ? console.createTask\n : function () {\n return null;\n };\n React = {\n react_stack_bottom_frame: function (callStackForError) {\n return callStackForError();\n }\n };\n var specialPropKeyWarningShown;\n var didWarnAboutElementRef = {};\n var unknownOwnerDebugStack = React.react_stack_bottom_frame.bind(\n React,\n UnknownOwner\n )();\n var unknownOwnerDebugTask = createTask(getTaskName(UnknownOwner));\n var didWarnAboutKeySpread = {};\n exports.Fragment = REACT_FRAGMENT_TYPE;\n exports.jsxDEV = function (type, config, maybeKey, isStaticChildren) {\n var trackActualOwner =\n 1e4 > ReactSharedInternals.recentlyCreatedOwnerStacks++;\n return jsxDEVImpl(\n type,\n config,\n maybeKey,\n isStaticChildren,\n trackActualOwner\n ? Error(\"react-stack-top-frame\")\n : unknownOwnerDebugStack,\n trackActualOwner ? createTask(getTaskName(type)) : unknownOwnerDebugTask\n );\n };\n })();\n",
|
|
8
|
+
"'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-jsx-dev-runtime.production.js');\n} else {\n module.exports = require('./cjs/react-jsx-dev-runtime.development.js');\n}\n",
|
|
9
|
+
"import { mkdirSync, writeFileSync } from \"node:fs\";\nimport { join } from \"node:path\";\nimport { scanForExports } from \"./scanner\";\nimport type {\n\tAutoImportGeneratorOptions,\n\tAutoImportManifest,\n\tDiscoveredExport,\n} from \"./types\";\n\nconst GENERATED_HEADER = `// This file is auto-generated by: bun rakta imports:generate\n// Do not edit manually. Re-generate whenever you add or remove files.\n// Note: Rakta Auto Import v0.1.0 produces a typed re-export layer.\n// Import from this file in your app code:\n// import { useCounterStore, http } from \"./.rakta/auto-imports\";\n`;\n\nfunction buildImportLines(exports: ReadonlyArray<DiscoveredExport>): string {\n\tif (exports.length === 0) {\n\t\treturn \"// No exports discovered. Check your autoImport.directories config.\\n\";\n\t}\n\n\treturn exports\n\t\t.map(\n\t\t\t(discoveredExport) => `export * from \"${discoveredExport.importPath}\";`,\n\t\t)\n\t\t.join(\"\\n\");\n}\n\nexport function generateAutoImports(\n\toptions: AutoImportGeneratorOptions,\n): AutoImportManifest {\n\tconst exports = scanForExports({\n\t\tfrontendRoot: options.frontendRoot,\n\t\tdirectories: options.directories,\n\t\toutputDirectory: options.outputDirectory,\n\t\t...(options.extensions\n\t\t\t? {\n\t\t\t\t\textensions: options.extensions,\n\t\t\t\t}\n\t\t\t: {}),\n\t});\n\n\tconst outputDir = join(options.frontendRoot, options.outputDirectory);\n\n\tmkdirSync(outputDir, {\n\t\trecursive: true,\n\t});\n\n\tconst tsContent = `${GENERATED_HEADER}\\n${buildImportLines(exports)}\\n`;\n\n\twriteFileSync(join(outputDir, \"auto-imports.ts\"), tsContent, \"utf-8\");\n\n\tif (options.generateDts) {\n\t\tconst dtsContent = tsContent.replace(\n\t\t\t\"// This file is auto-generated by: bun rakta imports:generate\",\n\t\t\t\"// Type declarations — auto-generated by: bun rakta imports:generate\",\n\t\t);\n\n\t\twriteFileSync(join(outputDir, \"auto-imports.d.ts\"), dtsContent, \"utf-8\");\n\t}\n\n\treturn {\n\t\tgeneratedAt: new Date().toISOString(),\n\t\tsourceDirectories: options.directories,\n\t\texports,\n\t};\n}\n\nexport function printAutoImportSummary(manifest: AutoImportManifest): void {\n\tconsole.log(\"\\n Rakta Auto Import\");\n\tconsole.log(` ${\"─\".repeat(50)}`);\n\tconsole.log(`Generated: ${manifest.generatedAt}`);\n\tconsole.log(`Exports: ${manifest.exports.length}`);\n\n\tif (manifest.exports.length > 0) {\n\t\tconsole.log(\"\");\n\n\t\tfor (const discoveredExport of manifest.exports) {\n\t\t\tconsole.log(\n\t\t\t\t`[${discoveredExport.kind.padEnd(10)}] ${discoveredExport.name} <- ${discoveredExport.filePath}`,\n\t\t\t);\n\t\t}\n\t}\n\n\tconsole.log(` ${\"─\".repeat(50)}\\n`);\n}\n",
|
|
10
|
+
"import { existsSync, readdirSync } from \"node:fs\";\nimport { basename, extname, join, relative } from \"node:path\";\nimport type { AutoImportKind, DiscoveredExport } from \"./types\";\n\nconst DEFAULT_EXTENSIONS: ReadonlyArray<string> = [\n\t\".ts\",\n\t\".tsx\",\n\t\".js\",\n\t\".jsx\",\n];\n\nfunction detectKind(filePath: string): AutoImportKind {\n\tconst lower = filePath.replace(/\\\\/g, \"/\").toLowerCase();\n\n\tif (\n\t\tlower.includes(\"/stores/\") ||\n\t\tlower.endsWith(\".store.ts\") ||\n\t\tlower.endsWith(\".store.tsx\")\n\t) {\n\t\treturn \"store\";\n\t}\n\n\tif (\n\t\tlower.includes(\"/schemas/\") ||\n\t\tlower.endsWith(\".schema.ts\") ||\n\t\tlower.endsWith(\".schema.tsx\")\n\t) {\n\t\treturn \"schema\";\n\t}\n\n\tif (lower.includes(\"/components/\")) {\n\t\treturn \"component\";\n\t}\n\n\tconst fileName = basename(lower);\n\n\tif (fileName.startsWith(\"use\")) {\n\t\treturn \"hook\";\n\t}\n\n\tif (\n\t\tlower.includes(\"/lib/\") ||\n\t\tlower.includes(\"/utils/\") ||\n\t\tlower.includes(\"/helpers/\")\n\t) {\n\t\treturn \"utils\";\n\t}\n\n\treturn \"unknown\";\n}\n\nfunction toPascalCase(text: string): string {\n\treturn text\n\t\t.replace(/[-_.]/g, \" \")\n\t\t.replace(/\\s+(.)/g, (_match: string, char: string) => char.toUpperCase())\n\t\t.replace(/^(.)/, (_match: string, char: string) => char.toUpperCase());\n}\n\nfunction deriveExportName(filePath: string, dirPath: string): string {\n\tconst relativePath = relative(dirPath, filePath).replace(/\\\\/g, \"/\");\n\n\tconst withoutExtension = relativePath\n\t\t.replace(/\\.(ts|tsx|js|jsx)$/, \"\")\n\t\t.replace(/\\/index$/, \"\");\n\n\treturn toPascalCase(withoutExtension.replace(/\\//g, \"_\"));\n}\n\nfunction walkDirectory(\n\tdirPath: string,\n\textensions: ReadonlyArray<string>,\n): string[] {\n\tif (!existsSync(dirPath)) {\n\t\treturn [];\n\t}\n\n\tconst collected: string[] = [];\n\n\tfunction walk(currentPath: string): void {\n\t\tconst entries = readdirSync(currentPath, {\n\t\t\twithFileTypes: true,\n\t\t});\n\n\t\tfor (const entry of entries) {\n\t\t\tif (entry.name.startsWith(\".\") || entry.name === \"node_modules\") {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\tconst fullPath = join(currentPath, entry.name);\n\n\t\t\tif (entry.isDirectory()) {\n\t\t\t\twalk(fullPath);\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\tif (entry.isFile() && extensions.includes(extname(entry.name))) {\n\t\t\t\tcollected.push(fullPath);\n\t\t\t}\n\t\t}\n\t}\n\n\twalk(dirPath);\n\n\treturn collected;\n}\n\nexport interface ScanForExportsOptions {\n\treadonly frontendRoot: string;\n\treadonly directories: ReadonlyArray<string>;\n\treadonly outputDirectory: string;\n\treadonly extensions?: ReadonlyArray<string>;\n}\n\nexport function scanForExports(\n\toptions: ScanForExportsOptions,\n): DiscoveredExport[] {\n\tconst extensions = options.extensions ?? DEFAULT_EXTENSIONS;\n\tconst discovered: DiscoveredExport[] = [];\n\tconst outputAbs = join(options.frontendRoot, options.outputDirectory);\n\n\tfor (const directory of options.directories) {\n\t\tconst directoryAbs = join(options.frontendRoot, directory);\n\n\t\tconst files = walkDirectory(directoryAbs, extensions);\n\n\t\tfor (const filePath of files) {\n\t\t\tconst relativeFromOutput = relative(outputAbs, filePath)\n\t\t\t\t.replace(/\\\\/g, \"/\")\n\t\t\t\t.replace(/\\.(ts|tsx)$/, \"\");\n\n\t\t\tconst importPath = relativeFromOutput.startsWith(\".\")\n\t\t\t\t? relativeFromOutput\n\t\t\t\t: `./${relativeFromOutput}`;\n\n\t\t\tdiscovered.push({\n\t\t\t\tname: deriveExportName(filePath, directoryAbs),\n\t\t\t\tfilePath: relative(options.frontendRoot, filePath).replace(/\\\\/g, \"/\"),\n\t\t\t\timportPath,\n\t\t\t\tkind: detectKind(filePath),\n\t\t\t});\n\t\t}\n\t}\n\n\treturn discovered;\n}\n",
|
|
11
|
+
"import React, {\n\ttype AnchorHTMLAttributes,\n\ttype CSSProperties,\n\ttype KeyboardEvent,\n\ttype MouseEvent,\n\ttype ReactElement,\n\ttype ReactNode,\n\tuseCallback,\n\tuseEffect,\n} from \"react\";\n\nexport interface ClickProps\n\textends Omit<AnchorHTMLAttributes<HTMLAnchorElement>, \"href\"> {\n\treadonly to: string;\n\treadonly prefetch?: boolean;\n\treadonly replace?: boolean;\n\treadonly activeClassName?: string;\n\treadonly children: ReactNode;\n}\n\ntype ClickElementAttributes = Omit<\n\tAnchorHTMLAttributes<HTMLAnchorElement>,\n\t\"href\"\n> & {\n\treadonly to: string;\n};\n\ninterface NavigationState {\n\treadonly source: \"rakta-click\";\n\treadonly to: string;\n}\n\nfunction isModifiedEvent(event: MouseEvent<HTMLAnchorElement>): boolean {\n\treturn event.metaKey || event.altKey || event.ctrlKey || event.shiftKey;\n}\n\nfunction isExternalTo(to: string): boolean {\n\treturn (\n\t\tto.startsWith(\"http://\") ||\n\t\tto.startsWith(\"https://\") ||\n\t\tto.startsWith(\"//\") ||\n\t\tto.startsWith(\"mailto:\") ||\n\t\tto.startsWith(\"tel:\")\n\t);\n}\n\nfunction getCurrentPathname(): string {\n\tif (typeof window === \"undefined\") {\n\t\treturn \"/\";\n\t}\n\n\treturn window.location.pathname;\n}\n\nfunction getCleanPathname(to: string): string {\n\tconst [pathname] = to.split(/[?#]/);\n\n\tif (pathname && pathname.length > 0) {\n\t\treturn pathname;\n\t}\n\n\treturn \"/\";\n}\n\nfunction getPathnameFromTo(to: string): string {\n\tconst cleanPathname = getCleanPathname(to);\n\n\tif (typeof window === \"undefined\") {\n\t\treturn cleanPathname;\n\t}\n\n\ttry {\n\t\treturn new URL(to, window.location.origin).pathname;\n\t} catch {\n\t\treturn cleanPathname;\n\t}\n}\n\nfunction createNavigationState(to: string): NavigationState {\n\treturn {\n\t\tsource: \"rakta-click\",\n\t\tto,\n\t};\n}\n\nfunction navigate(to: string, shouldReplace: boolean): void {\n\tif (typeof window === \"undefined\") {\n\t\treturn;\n\t}\n\n\tconst navigationState = createNavigationState(to);\n\n\tif (shouldReplace) {\n\t\twindow.history.replaceState(navigationState, \"\", to);\n\t} else {\n\t\twindow.history.pushState(navigationState, \"\", to);\n\t}\n\n\twindow.dispatchEvent(\n\t\tnew PopStateEvent(\"popstate\", {\n\t\t\tstate: navigationState,\n\t\t}),\n\t);\n}\n\nfunction openExternalTo(to: string, target: string): void {\n\tif (typeof window === \"undefined\") {\n\t\treturn;\n\t}\n\n\tif (target === \"_blank\") {\n\t\twindow.open(to, \"_blank\", \"noopener,noreferrer\");\n\t\treturn;\n\t}\n\n\twindow.location.assign(to);\n}\n\nfunction prefetchPage(to: string): void {\n\tif (typeof window === \"undefined\" || typeof document === \"undefined\") {\n\t\treturn;\n\t}\n\n\tconst targetUrl = new URL(to, window.location.origin).href;\n\tconst existingLinks = Array.from(\n\t\tdocument.querySelectorAll<HTMLLinkElement>('link[rel=\"prefetch\"]'),\n\t);\n\n\tconst alreadyPrefetched = existingLinks.some(\n\t\t(link) => link.href === targetUrl,\n\t);\n\n\tif (alreadyPrefetched) {\n\t\treturn;\n\t}\n\n\tconst link = document.createElement(\"link\");\n\n\tlink.rel = \"prefetch\";\n\tlink.href = targetUrl;\n\tlink.as = \"document\";\n\n\tdocument.head.appendChild(link);\n}\n\nfunction mergeClassNames(\n\tclassName: string | undefined,\n\tactiveClassName: string | undefined,\n\tisActive: boolean,\n): string {\n\tconst classNames: string[] = [];\n\n\tif (className && className.length > 0) {\n\t\tclassNames.push(className);\n\t}\n\n\tif (isActive && activeClassName && activeClassName.length > 0) {\n\t\tclassNames.push(activeClassName);\n\t}\n\n\treturn classNames.join(\" \");\n}\n\nfunction applyClassName(\n\tclickAttributes: ClickElementAttributes,\n\tclassName: string,\n): void {\n\tif (className.length === 0) {\n\t\treturn;\n\t}\n\n\tclickAttributes.className = className;\n}\n\nfunction applyStyle(\n\tclickAttributes: ClickElementAttributes,\n\tstyle: CSSProperties | undefined,\n): void {\n\tif (!style) {\n\t\treturn;\n\t}\n\n\tclickAttributes.style = style;\n}\n\nfunction applyInternalAttributes(\n\tclickAttributes: ClickElementAttributes,\n\ttarget: AnchorHTMLAttributes<HTMLAnchorElement>[\"target\"],\n\trel: string | undefined,\n\tisActive: boolean,\n): void {\n\tif (target) {\n\t\tclickAttributes.target = target;\n\t}\n\n\tif (rel && rel.length > 0) {\n\t\tclickAttributes.rel = rel;\n\t}\n\n\tif (isActive) {\n\t\tclickAttributes[\"aria-current\"] = \"page\";\n\t}\n}\n\nfunction applyExternalAttributes(\n\tclickAttributes: ClickElementAttributes,\n\ttarget: AnchorHTMLAttributes<HTMLAnchorElement>[\"target\"],\n\trel: string | undefined,\n): void {\n\tclickAttributes.target = target ?? \"_blank\";\n\tclickAttributes.rel = rel && rel.length > 0 ? rel : \"noopener noreferrer\";\n}\n\nfunction renderClickElement(\n\tattributes: ClickElementAttributes,\n\tchildren: ReactNode,\n): ReactElement {\n\treturn React.createElement(\"click\", attributes, children);\n}\n\nexport function Click({\n\tto,\n\tprefetch = false,\n\treplace = false,\n\tactiveClassName,\n\tclassName,\n\tchildren,\n\tonClick,\n\tonKeyDown,\n\tstyle,\n\ttarget,\n\trel,\n\t...restAttributes\n}: ClickProps): ReactElement {\n\tconst isExternal = isExternalTo(to);\n\tconst isActive =\n\t\t!isExternal && getCurrentPathname() === getPathnameFromTo(to);\n\n\tconst resolvedClassName = mergeClassNames(\n\t\tclassName,\n\t\tactiveClassName,\n\t\tisActive,\n\t);\n\n\tuseEffect(() => {\n\t\tif (!prefetch || isExternal) {\n\t\t\treturn;\n\t\t}\n\n\t\tprefetchPage(to);\n\t}, [prefetch, isExternal, to]);\n\n\tconst handleClick = useCallback(\n\t\t(event: MouseEvent<HTMLAnchorElement>): void => {\n\t\t\tonClick?.(event);\n\n\t\t\tif (event.defaultPrevented || isModifiedEvent(event)) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tif (isExternal) {\n\t\t\t\tevent.preventDefault();\n\t\t\t\topenExternalTo(to, target ?? \"_blank\");\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tif (target === \"_blank\") {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tevent.preventDefault();\n\t\t\tnavigate(to, replace);\n\t\t},\n\t\t[isExternal, onClick, replace, target, to],\n\t);\n\n\tconst handleKeyDown = useCallback(\n\t\t(event: KeyboardEvent<HTMLAnchorElement>): void => {\n\t\t\tonKeyDown?.(event);\n\n\t\t\tif (event.defaultPrevented || event.key !== \"Enter\") {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tif (isExternal) {\n\t\t\t\tevent.preventDefault();\n\t\t\t\topenExternalTo(to, target ?? \"_blank\");\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tif (target === \"_blank\") {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tevent.preventDefault();\n\t\t\tnavigate(to, replace);\n\t\t},\n\t\t[isExternal, onKeyDown, replace, target, to],\n\t);\n\n\tconst clickAttributes: ClickElementAttributes = {\n\t\t...restAttributes,\n\t\tto,\n\t\tonClick: handleClick,\n\t\tonKeyDown: handleKeyDown,\n\t};\n\n\tapplyClassName(clickAttributes, resolvedClassName);\n\tapplyStyle(clickAttributes, style);\n\n\tif (isExternal) {\n\t\tapplyExternalAttributes(clickAttributes, target, rel);\n\t} else {\n\t\tapplyInternalAttributes(clickAttributes, target, rel, isActive);\n\t}\n\n\treturn renderClickElement(clickAttributes, children);\n}\n\nexport default Click;\n",
|
|
12
|
+
"import React, {\n\ttype CSSProperties,\n\ttype HTMLAttributes,\n\tuseCallback,\n\tuseEffect,\n\tuseRef,\n\tuseState,\n} from \"react\";\n\ntype ObjectFitValue = \"contain\" | \"cover\" | \"fill\" | \"none\" | \"scale-down\";\ntype LoadingValue = \"lazy\" | \"eager\" | \"auto\";\n\nexport interface PictureProps\n\textends Omit<\n\t\tHTMLAttributes<HTMLPictureElement>,\n\t\t\"children\" | \"onError\" | \"onLoad\"\n\t> {\n\tpath: string;\n\talt: string;\n\ttitle?: string;\n\theight?: number;\n\twidth?: number;\n\tloading?: LoadingValue;\n\tresponsive?: boolean;\n\tblurDataURL?: string;\n\tobjectFit?: ObjectFitValue;\n\tpriority?: boolean;\n\tonLoadComplete?: () => void;\n\tonError?: () => void;\n\tclassName?: string;\n\tstyle?: CSSProperties;\n}\n\nexport function Picture({\n\tpath,\n\talt,\n\ttitle,\n\theight,\n\twidth,\n\tblurDataURL,\n\tonLoadComplete,\n\tonError,\n\tclassName,\n\tstyle,\n\tloading = \"lazy\",\n\tresponsive = true,\n\tobjectFit = \"cover\",\n\tpriority = false,\n\t...rest\n}: PictureProps): React.ReactElement {\n\tconst [isLoaded, setIsLoaded] = useState(false);\n\tconst [hasError, setHasError] = useState(false);\n\tconst imageRef = useRef<HTMLImageElement>(null);\n\tconst pictureRef = useRef<HTMLPictureElement>(null);\n\n\tconst resolvedLoading: \"lazy\" | \"eager\" = priority\n\t\t? \"eager\"\n\t\t: loading === \"auto\"\n\t\t\t? \"lazy\"\n\t\t\t: loading;\n\n\tuseEffect(() => {\n\t\tconst imageElement = imageRef.current;\n\n\t\tif (imageElement?.complete) {\n\t\t\tsetIsLoaded(true);\n\t\t\tonLoadComplete?.();\n\t\t}\n\t}, [onLoadComplete]);\n\n\tconst handleLoad = useCallback(() => {\n\t\tsetIsLoaded(true);\n\t\tonLoadComplete?.();\n\t}, [onLoadComplete]);\n\n\tconst handleError = useCallback(() => {\n\t\tsetHasError(true);\n\t\tonError?.();\n\t}, [onError]);\n\n\tconst resolvedPath = hasError && blurDataURL ? blurDataURL : path;\n\tconst resolvedWidth = responsive ? \"100%\" : (width ?? \"auto\");\n\n\tconst wrapperStyle: CSSProperties = {\n\t\tposition: \"relative\",\n\t\tdisplay: \"inline-block\",\n\t\toverflow: \"hidden\",\n\t\theight: height ?? \"auto\",\n\t\twidth: resolvedWidth,\n\t};\n\n\tconst imageStyle: CSSProperties = {\n\t\tdisplay: \"block\",\n\t\theight: height ?? undefined,\n\t\twidth: resolvedWidth,\n\t\tminHeight: height ?? undefined,\n\t\tobjectFit,\n\t\ttransition: blurDataURL ? \"filter 0.3s ease\" : undefined,\n\t\tfilter:\n\t\t\tblurDataURL && !isLoaded && !hasError\n\t\t\t\t? \"blur(12px) brightness(1.05)\"\n\t\t\t\t: \"none\",\n\t\t...style,\n\t};\n\n\tif (blurDataURL) {\n\t\treturn (\n\t\t\t<div\n\t\t\t\tstyle={{\n\t\t\t\t\t...wrapperStyle,\n\t\t\t\t\tbackgroundImage: `url(${blurDataURL})`,\n\t\t\t\t\tbackgroundSize: \"cover\",\n\t\t\t\t\tbackgroundPosition: \"center\",\n\t\t\t\t}}\n\t\t\t>\n\t\t\t\t<picture ref={pictureRef} className={className} {...rest}>\n\t\t\t\t\t<img\n\t\t\t\t\t\tref={imageRef}\n\t\t\t\t\t\tsrc={resolvedPath}\n\t\t\t\t\t\talt={alt}\n\t\t\t\t\t\taria-label={alt}\n\t\t\t\t\t\ttitle={title}\n\t\t\t\t\t\tloading={resolvedLoading}\n\t\t\t\t\t\tdecoding={priority ? \"sync\" : \"async\"}\n\t\t\t\t\t\tstyle={imageStyle}\n\t\t\t\t\t\tonLoad={handleLoad}\n\t\t\t\t\t\tonError={handleError}\n\t\t\t\t\t/>\n\t\t\t\t</picture>\n\t\t\t</div>\n\t\t);\n\t}\n\n\treturn (\n\t\t<picture ref={pictureRef} className={className} {...rest}>\n\t\t\t<img\n\t\t\t\tref={imageRef}\n\t\t\t\tsrc={resolvedPath}\n\t\t\t\talt={alt}\n\t\t\t\taria-label={alt}\n\t\t\t\ttitle={title}\n\t\t\t\tloading={resolvedLoading}\n\t\t\t\tdecoding={priority ? \"sync\" : \"async\"}\n\t\t\t\tstyle={imageStyle}\n\t\t\t\tonLoad={handleLoad}\n\t\t\t\tonError={handleError}\n\t\t\t/>\n\t\t</picture>\n\t);\n}\n\nexport default Picture;\n",
|
|
13
|
+
"import type { RenderConfig } from \"../render/types\";\n\nexport interface CssConfig {\n\treadonly framework: \"tailwind\" | \"bootstrap\" | \"sass\" | \"none\";\n\n\treadonly configPath?: string;\n}\n\nexport interface SeoConfig {\n\treadonly defaultTitle?: string;\n\treadonly titleTemplate?: string;\n\treadonly defaultDescription?: string;\n\treadonly siteUrl?: string;\n\treadonly defaultOpenGraphImage?: string;\n}\n\nexport interface CorsConfig {\n\treadonly origin: string | string[];\n\treadonly methods?: string[];\n\treadonly headers?: string[];\n\treadonly credentials?: boolean;\n\treadonly maxAge?: number;\n}\n\nexport interface ServerConfig {\n\treadonly port?: number;\n\treadonly hostname?: string;\n\treadonly cors?: boolean | CorsConfig;\n\treadonly compression?: boolean;\n\treadonly trustProxy?: boolean;\n}\n\nexport interface BuildConfig {\n\treadonly entryPoint?: string;\n\treadonly outDir?: string;\n\treadonly sourcemap?: boolean;\n\treadonly minify?: boolean;\n\treadonly splitting?: boolean;\n\treadonly target?: \"browser\" | \"bun\" | \"node\";\n}\n\nexport interface AutoImportConfig {\n\treadonly enabled: boolean;\n\treadonly directories: string[];\n\treadonly outputDirectory: string;\n\treadonly extensions?: string[];\n\treadonly dts?: boolean;\n}\n\nexport interface RpcConfig {\n\treadonly enabled: boolean;\n\treadonly basePath?: string;\n\treadonly maxBodySize?: number;\n}\n\nexport interface RaktaConfig {\n\treadonly appName?: string;\n\treadonly appDir?: string;\n\treadonly publicDir?: string;\n\treadonly port?: number;\n\treadonly css?: CssConfig;\n\treadonly seo?: SeoConfig;\n\treadonly server?: ServerConfig;\n\treadonly build?: BuildConfig;\n\treadonly autoImport?: AutoImportConfig;\n\treadonly rpc?: RpcConfig;\n\treadonly render?: RenderConfig;\n}\n\nexport function defineConfig(config: RaktaConfig): RaktaConfig {\n\treturn config;\n}\n\n/** Alias matching the config example in the docs. */\nexport const defineRaktaConfig = defineConfig;\n\nexport const defaultConfig: Required<RaktaConfig> = {\n\tappName: \"Rakta.js App\",\n\tappDir: \"app\",\n\tpublicDir: \"public\",\n\tport: 3000,\n\tcss: {\n\t\tframework: \"tailwind\",\n\t},\n\tseo: {\n\t\tdefaultTitle: \"Rakta.js App\",\n\t\ttitleTemplate: \"%s | Rakta.js App\",\n\t\tdefaultDescription: \"Built with Rakta.js\",\n\t\tsiteUrl: \"http://localhost:3000\",\n\t},\n\tserver: {\n\t\tport: 3000,\n\t\thostname: \"0.0.0.0\",\n\t\tcors: true,\n\t\tcompression: false,\n\t\ttrustProxy: false,\n\t},\n\tbuild: {\n\t\tentryPoint: \"entry.client.tsx\",\n\t\toutDir: \"dist\",\n\t\tsourcemap: false,\n\t\tminify: true,\n\t\tsplitting: false,\n\t\ttarget: \"browser\",\n\t},\n\tautoImport: {\n\t\tenabled: false,\n\t\tdirectories: [\"components\", \"lib\", \"stores\", \"schemas\"],\n\t\toutputDirectory: \".rakta\",\n\t\textensions: [\".ts\", \".tsx\", \".js\", \".jsx\"],\n\t\tdts: true,\n\t},\n\trpc: {\n\t\tenabled: false,\n\t\tbasePath: \"/rpc\",\n\t\tmaxBodySize: 1_048_576,\n\t},\n\trender: {\n\t\tdefaultMode: \"csr\",\n\t\troutes: {},\n\t},\n};\n",
|
|
14
|
+
"import { existsSync } from \"node:fs\";\nimport { join, resolve } from \"node:path\";\nimport type { RaktaConfig } from \"./defineConfig\";\nimport { defaultConfig } from \"./defineConfig\";\n\nconst CONFIG_FILENAMES: ReadonlyArray<string> = [\n\t\"rakta.config.ts\",\n\t\"rakta.config.js\",\n\t\"rakta.config.mts\",\n\t\"rakta.config.mjs\",\n];\n\nexport async function loadConfig(\n\tcwd: string = process.cwd(),\n): Promise<Required<RaktaConfig>> {\n\tconst resolvedCwd = resolve(cwd);\n\n\tfor (const filename of CONFIG_FILENAMES) {\n\t\tconst configPath = join(resolvedCwd, filename);\n\n\t\tif (!existsSync(configPath)) {\n\t\t\tcontinue;\n\t\t}\n\n\t\tconst configModule = (await import(configPath)) as {\n\t\t\tdefault?: RaktaConfig;\n\t\t};\n\t\tconst userConfig: RaktaConfig = configModule.default ?? {};\n\n\t\treturn mergeConfig(defaultConfig, userConfig);\n\t}\n\n\treturn defaultConfig;\n}\n\nexport function mergeConfig(\n\tbaseConfig: Required<RaktaConfig>,\n\toverrideConfig: RaktaConfig,\n): Required<RaktaConfig> {\n\treturn {\n\t\tappName: overrideConfig.appName ?? baseConfig.appName,\n\t\tappDir: overrideConfig.appDir ?? baseConfig.appDir,\n\t\tpublicDir: overrideConfig.publicDir ?? baseConfig.publicDir,\n\t\tport: overrideConfig.port ?? baseConfig.port,\n\t\tcss:\n\t\t\toverrideConfig.css !== undefined\n\t\t\t\t? { ...baseConfig.css, ...overrideConfig.css }\n\t\t\t\t: baseConfig.css,\n\t\tseo:\n\t\t\toverrideConfig.seo !== undefined\n\t\t\t\t? { ...baseConfig.seo, ...overrideConfig.seo }\n\t\t\t\t: baseConfig.seo,\n\t\tserver:\n\t\t\toverrideConfig.server !== undefined\n\t\t\t\t? { ...baseConfig.server, ...overrideConfig.server }\n\t\t\t\t: baseConfig.server,\n\t\tbuild:\n\t\t\toverrideConfig.build !== undefined\n\t\t\t\t? { ...baseConfig.build, ...overrideConfig.build }\n\t\t\t\t: baseConfig.build,\n\t\tautoImport:\n\t\t\toverrideConfig.autoImport !== undefined\n\t\t\t\t? { ...baseConfig.autoImport, ...overrideConfig.autoImport }\n\t\t\t\t: baseConfig.autoImport,\n\t\trpc:\n\t\t\toverrideConfig.rpc !== undefined\n\t\t\t\t? { ...baseConfig.rpc, ...overrideConfig.rpc }\n\t\t\t\t: baseConfig.rpc,\n\t\trender:\n\t\t\toverrideConfig.render !== undefined\n\t\t\t\t? {\n\t\t\t\t\t\tdefaultMode:\n\t\t\t\t\t\t\toverrideConfig.render.defaultMode ??\n\t\t\t\t\t\t\tbaseConfig.render.defaultMode,\n\t\t\t\t\t\troutes: {\n\t\t\t\t\t\t\t...baseConfig.render.routes,\n\t\t\t\t\t\t\t...overrideConfig.render.routes,\n\t\t\t\t\t\t},\n\t\t\t\t\t}\n\t\t\t\t: baseConfig.render,\n\t};\n}\n",
|
|
15
|
+
"import { mkdirSync } from \"node:fs\";\nimport { join, resolve } from \"node:path\";\nimport { generateManifest, writeManifest } from \"../router/manifest\";\nimport type {\n\tForgeBuildArtifact,\n\tForgeBuildOptions,\n\tForgeBuildResult,\n} from \"./types\";\n\n/**\n * Runs the Rakta.js Forge build pipeline.\n * Uses Bun.build for bundling. Generates a route manifest alongside the bundle.\n */\nexport async function buildProject(\n\toptions: ForgeBuildOptions,\n): Promise<ForgeBuildResult> {\n\tconst startMs = Date.now();\n\tconst artifacts: ForgeBuildArtifact[] = [];\n\tconst errors: string[] = [];\n\n\tmkdirSync(resolve(options.outDir), { recursive: true });\n\n\t// Generate and write route manifest\n\tconst manifest = generateManifest(options.appDir);\n\tconst manifestPath = join(options.outDir, \"route-manifest.json\");\n\twriteManifest(manifest, manifestPath);\n\n\tconst manifestContent = JSON.stringify(manifest);\n\tartifacts.push({\n\t\toutputPath: manifestPath,\n\t\tsizeBytes: new TextEncoder().encode(manifestContent).byteLength,\n\t\tkind: \"manifest\",\n\t});\n\n\t// Build JavaScript bundle\n\tconst buildResult = await Bun.build({\n\t\tentrypoints: [options.entryPoint],\n\t\toutdir: options.outDir,\n\t\ttarget: options.target,\n\t\tminify: options.minify,\n\t\tsourcemap: options.sourcemap ? \"external\" : \"none\",\n\t\tsplitting: options.splitting,\n\t\tnaming: {\n\t\t\tentry: \"[name].[ext]\",\n\t\t\tchunk: \"chunks/[name]-[hash].[ext]\",\n\t\t\tasset: \"assets/[name]-[hash].[ext]\",\n\t\t},\n\t});\n\n\tif (!buildResult.success) {\n\t\tfor (const log of buildResult.logs) {\n\t\t\terrors.push(log.message);\n\t\t}\n\t\treturn {\n\t\t\tsuccess: false,\n\t\t\tartifacts,\n\t\t\tmanifest,\n\t\t\tbuildMs: Date.now() - startMs,\n\t\t\terrors,\n\t\t};\n\t}\n\n\tfor (const output of buildResult.outputs) {\n\t\tartifacts.push({\n\t\t\toutputPath: output.path,\n\t\t\tsizeBytes: output.size,\n\t\t\tkind: output.path.endsWith(\".css\") ? \"stylesheet\" : \"script\",\n\t\t});\n\t}\n\n\treturn {\n\t\tsuccess: true,\n\t\tartifacts,\n\t\tmanifest,\n\t\tbuildMs: Date.now() - startMs,\n\t\terrors: [],\n\t};\n}\n",
|
|
16
|
+
"import { existsSync, readFileSync, writeFileSync } from \"node:fs\";\nimport { scanRoutes } from \"./scanner\";\nimport type { RouteManifest } from \"./types\";\n\nexport function generateManifest(appDir: string): RouteManifest {\n\tconst routes = scanRoutes({ appDir });\n\n\tconst manifest: RouteManifest = {\n\t\tversion: \"1\",\n\t\tgeneratedAt: new Date().toISOString(),\n\t\troutes,\n\t};\n\n\treturn manifest;\n}\n\nexport function writeManifest(\n\tmanifest: RouteManifest,\n\toutputPath: string,\n): void {\n\twriteFileSync(outputPath, JSON.stringify(manifest, null, 2), \"utf-8\");\n}\n\nexport function readManifest(manifestPath: string): RouteManifest | null {\n\tif (!existsSync(manifestPath)) return null;\n\n\tconst raw = readFileSync(manifestPath, \"utf-8\");\n\n\tconst parsed: unknown = JSON.parse(raw);\n\tif (\n\t\ttypeof parsed !== \"object\" ||\n\t\tparsed === null ||\n\t\t!(\"version\" in parsed) ||\n\t\t!(\"routes\" in parsed)\n\t) {\n\t\treturn null;\n\t}\n\n\treturn parsed as RouteManifest;\n}\n\nexport function printManifest(manifest: RouteManifest): void {\n\tconst pageRoutes = manifest.routes.filter((route) => route.kind === \"page\");\n\tconst apiRoutes = manifest.routes.filter((route) => route.kind === \"api\");\n\tconst layoutRoutes = manifest.routes.filter(\n\t\t(route) => route.kind === \"layout\",\n\t);\n\tconst specialRoutes = manifest.routes.filter((route) =>\n\t\t[\"loading\", \"not-found\", \"error\"].includes(route.kind),\n\t);\n\n\tconst line = \"─\".repeat(56);\n\n\tconsole.log(`\\n Rakta.js Route Manifest`);\n\tconsole.log(` ${line}`);\n\tconsole.log(` Generated: ${manifest.generatedAt}`);\n\tconsole.log(` Total: ${manifest.routes.length} routes\\n`);\n\n\tif (pageRoutes.length > 0) {\n\t\tconsole.log(\" Pages:\");\n\t\tfor (const route of pageRoutes) {\n\t\t\tconst dynamic = route.isDynamic\n\t\t\t\t? ` [params: ${route.paramNames.join(\", \")}]`\n\t\t\t\t: \"\";\n\t\t\tconsole.log(` GET ${route.urlPattern}${dynamic}`);\n\t\t}\n\t\tconsole.log(\"\");\n\t}\n\n\tif (apiRoutes.length > 0) {\n\t\tconsole.log(\" API Routes:\");\n\t\tfor (const route of apiRoutes) {\n\t\t\tconst dynamic = route.isDynamic\n\t\t\t\t? ` [params: ${route.paramNames.join(\", \")}]`\n\t\t\t\t: \"\";\n\t\t\tconsole.log(` ANY ${route.urlPattern}${dynamic}`);\n\t\t}\n\t\tconsole.log(\"\");\n\t}\n\n\tif (layoutRoutes.length > 0) {\n\t\tconsole.log(\" Layouts:\");\n\t\tfor (const route of layoutRoutes) {\n\t\t\tconsole.log(\n\t\t\t\t` ${route.urlPattern === \"/\" ? \"root\" : route.urlPattern}`,\n\t\t\t);\n\t\t}\n\t\tconsole.log(\"\");\n\t}\n\n\tif (specialRoutes.length > 0) {\n\t\tconsole.log(\" Special:\");\n\t\tfor (const route of specialRoutes) {\n\t\t\tconsole.log(` [${route.kind}] ${route.filePath}`);\n\t\t}\n\t\tconsole.log(\"\");\n\t}\n\n\tconsole.log(` ${line}\\n`);\n}\n",
|
|
17
|
+
"import { existsSync, readdirSync, statSync } from \"node:fs\";\nimport { join, relative } from \"node:path\";\nimport type { RouteKind, RouteManifestEntry, RouteSegment } from \"./types.js\";\n\nconst FILE_TO_KIND: Record<string, RouteKind> = {\n\t\"page.tsx\": \"page\",\n\t\"page.ts\": \"page\",\n\t\"page.jsx\": \"page\",\n\t\"page.js\": \"page\",\n\t\"layout.tsx\": \"layout\",\n\t\"layout.ts\": \"layout\",\n\t\"layout.jsx\": \"layout\",\n\t\"layout.js\": \"layout\",\n\t\"loading.tsx\": \"loading\",\n\t\"loading.ts\": \"loading\",\n\t\"loading.jsx\": \"loading\",\n\t\"loading.js\": \"loading\",\n\t\"notFound.tsx\": \"notFound\",\n\t\"notFound.ts\": \"notFound\",\n\t\"notFound.jsx\": \"notFound\",\n\t\"notFound.js\": \"notFound\",\n\t\"error.tsx\": \"error\",\n\t\"error.ts\": \"error\",\n\t\"error.jsx\": \"error\",\n\t\"error.js\": \"error\",\n\t\"route.ts\": \"api\",\n\t\"route.js\": \"api\",\n};\n\nfunction parseSegment(raw: string): RouteSegment {\n\tconst isDynamic = raw.startsWith(\"[\") && raw.endsWith(\"]\");\n\tconst paramName = isDynamic ? raw.slice(1, -1) : \"\";\n\n\treturn { raw, isDynamic, paramName };\n}\n\nfunction collectParamNames(segments: RouteSegment[]): string[] {\n\treturn segments\n\t\t.filter((segment) => segment.isDynamic && segment.paramName.length > 0)\n\t\t.map((segment) => segment.paramName);\n}\n\nfunction segmentsToUrlPattern(segments: RouteSegment[]): string {\n\tif (segments.length === 0) return \"/\";\n\tconst parts = segments.map((segment) =>\n\t\tsegment.isDynamic && segment.paramName\n\t\t\t? `:${segment.paramName}`\n\t\t\t: segment.raw,\n\t);\n\treturn `/${parts.join(\"/\")}`;\n}\n\nfunction scanDirectory(\n\tdirPath: string,\n\tappRoot: string,\n\tresults: RouteManifestEntry[],\n): void {\n\tif (!existsSync(dirPath)) return;\n\n\tconst entries = readdirSync(dirPath);\n\n\tfor (const entryName of entries) {\n\t\tconst fullPath = join(dirPath, entryName);\n\t\tconst stats = statSync(fullPath);\n\n\t\tif (stats.isDirectory()) {\n\t\t\tscanDirectory(fullPath, appRoot, results);\n\t\t\tcontinue;\n\t\t}\n\n\t\tif (!stats.isFile()) continue;\n\n\t\tconst kind = FILE_TO_KIND[entryName];\n\t\tif (!kind) continue;\n\n\t\t// Get path relative to app root, using forward slashes\n\t\tconst relativePath = relative(appRoot, fullPath).replace(/\\\\/g, \"/\");\n\n\t\t// Extract directory segments (all parts except the filename)\n\t\tconst dirRelative = relative(appRoot, dirPath).replace(/\\\\/g, \"/\");\n\t\tconst rawSegments = dirRelative === \"\" ? [] : dirRelative.split(\"/\");\n\n\t\tconst segments: RouteSegment[] = rawSegments.map(parseSegment);\n\t\tconst urlPattern = segmentsToUrlPattern(segments);\n\t\tconst paramNames = collectParamNames(segments);\n\t\tconst isDynamic = paramNames.length > 0;\n\n\t\tresults.push({\n\t\t\tfilePath: relativePath,\n\t\t\turlPattern,\n\t\t\tkind,\n\t\t\tsegments,\n\t\t\tisDynamic,\n\t\t\tparamNames,\n\t\t});\n\t}\n}\n\nexport interface ScanOptions {\n\tappDir: string;\n}\n\nexport function scanRoutes(options: ScanOptions): RouteManifestEntry[] {\n\tconst results: RouteManifestEntry[] = [];\n\tscanDirectory(options.appDir, options.appDir, results);\n\n\t// Sort: static routes before dynamic, shorter patterns first\n\tresults.sort((routeA, routeB) => {\n\t\tif (routeA.isDynamic !== routeB.isDynamic) {\n\t\t\treturn routeA.isDynamic ? 1 : -1;\n\t\t}\n\t\treturn routeA.urlPattern.localeCompare(routeB.urlPattern);\n\t});\n\n\treturn results;\n}\n",
|
|
18
|
+
"import { existsSync, readFileSync } from \"node:fs\";\nimport { join } from \"node:path\";\nimport { resolveRouteMode } from \"../render/modes\";\nimport { render } from \"../render/renderer\";\nimport { generateManifest } from \"../router/manifest\";\nimport { matchRoute } from \"../router/matcher\";\nimport type { ForgeDevServerHandle, ForgeDevServerOptions } from \"./types\";\n\nconst DEFAULT_DEV_PORT = 3000;\n\nconst MIME_MAP: Readonly<Record<string, string>> = {\n\t\".html\": \"text/html; charset=utf-8\",\n\t\".js\": \"application/javascript; charset=utf-8\",\n\t\".mjs\": \"application/javascript; charset=utf-8\",\n\t\".css\": \"text/css; charset=utf-8\",\n\t\".json\": \"application/json; charset=utf-8\",\n\t\".png\": \"image/png\",\n\t\".jpg\": \"image/jpeg\",\n\t\".jpeg\": \"image/jpeg\",\n\t\".webp\": \"image/webp\",\n\t\".svg\": \"image/svg+xml\",\n\t\".ico\": \"image/x-icon\",\n\t\".woff\": \"font/woff\",\n\t\".woff2\": \"font/woff2\",\n\t\".ttf\": \"font/ttf\",\n};\n\nfunction resolveMime(filePath: string): string {\n\tconst ext = filePath.slice(filePath.lastIndexOf(\".\")).toLowerCase();\n\treturn MIME_MAP[ext] ?? \"application/octet-stream\";\n}\n\nfunction resolveDevPort(port: number): number {\n\treturn port > 0 ? port : DEFAULT_DEV_PORT;\n}\n\ninterface ApiRouteExports {\n\tGET?: (request: Request) => Promise<Response>;\n\tPOST?: (request: Request) => Promise<Response>;\n\tPUT?: (request: Request) => Promise<Response>;\n\tPATCH?: (request: Request) => Promise<Response>;\n\tDELETE?: (request: Request) => Promise<Response>;\n\tHEAD?: (request: Request) => Promise<Response>;\n\tOPTIONS?: (request: Request) => Promise<Response>;\n}\n\n/**\n * Starts the Rakta.js Forge development server.\n * Powered by Bun.serve. HMR is a roadmap feature (v0.2.0).\n */\nexport function startDevServer(\n\toptions: ForgeDevServerOptions,\n): ForgeDevServerHandle {\n\tconst manifest = generateManifest(options.appDir);\n\tconst resolvedPort = resolveDevPort(options.port);\n\n\tconst server = Bun.serve({\n\t\tport: resolvedPort,\n\t\thostname: options.host,\n\n\t\tasync fetch(request: Request): Promise<Response> {\n\t\t\tconst url = new URL(request.url);\n\t\t\tconst { pathname } = url;\n\n\t\t\t// Serve static files from public dir\n\t\t\tconst publicPath = join(options.publicDir, pathname);\n\t\t\tif (existsSync(publicPath) && !publicPath.endsWith(\"/\")) {\n\t\t\t\treturn new Response(readFileSync(publicPath), {\n\t\t\t\t\theaders: { \"Content-Type\": resolveMime(pathname) },\n\t\t\t\t});\n\t\t\t}\n\n\t\t\t// Match API routes\n\t\t\tconst apiMatch = matchRoute(\n\t\t\t\tpathname,\n\t\t\t\tmanifest.routes.filter((route) => route.kind === \"api\"),\n\t\t\t);\n\n\t\t\tif (apiMatch) {\n\t\t\t\tconst modulePath = join(options.appDir, apiMatch.entry.filePath);\n\t\t\t\tconst routeModule = (await import(modulePath)) as ApiRouteExports;\n\t\t\t\tconst method = request.method.toUpperCase() as keyof ApiRouteExports;\n\t\t\t\tconst handler = routeModule[method];\n\n\t\t\t\tif (typeof handler !== \"function\") {\n\t\t\t\t\treturn new Response(\"Method not allowed\", { status: 405 });\n\t\t\t\t}\n\n\t\t\t\treturn await handler(request);\n\t\t\t}\n\n\t\t\t// Resolve render mode and serve HTML shell for page routes\n\t\t\tconst resolved = resolveRouteMode(pathname, options.renderConfig);\n\n\t\t\tconst searchParams: Record<string, string> = {};\n\t\t\turl.searchParams.forEach((value, key) => {\n\t\t\t\tsearchParams[key] = value;\n\t\t\t});\n\n\t\t\tconst requestHeaders: Record<string, string> = {};\n\t\t\trequest.headers.forEach((value, key) => {\n\t\t\t\trequestHeaders[key] = value;\n\t\t\t});\n\n\t\t\tconst result = await render(\n\t\t\t\t{\n\t\t\t\t\troutePath: pathname,\n\t\t\t\t\tmode: resolved.mode,\n\t\t\t\t\tparams: {},\n\t\t\t\t\tsearchParams,\n\t\t\t\t\trequestHeaders,\n\t\t\t\t\ttimestampMs: Date.now(),\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\tappName: options.appName,\n\t\t\t\t\tscriptPath: \"/app.js\",\n\t\t\t\t\tcssPath: \"/globals.css\",\n\t\t\t\t\tlang: \"en\",\n\t\t\t\t},\n\t\t\t);\n\n\t\t\tif (result.kind === \"failure\") {\n\t\t\t\treturn new Response(result.reason, { status: result.httpStatus });\n\t\t\t}\n\n\t\t\treturn new Response(result.html, {\n\t\t\t\tstatus: result.httpStatus,\n\t\t\t\theaders: result.responseHeaders,\n\t\t\t});\n\t\t},\n\t});\n\n\tconst serverPort =\n\t\ttypeof server.port === \"number\" ? server.port : resolvedPort;\n\n\treturn {\n\t\tport: serverPort,\n\t\thost: options.host,\n\t\turl: `http://${options.host}:${serverPort}`,\n\t\tstop: () => server.stop(),\n\t};\n}\n",
|
|
19
|
+
"import type {\n\tRenderConfig,\n\tRenderMode,\n\tRenderModeDescriptor,\n\tResolvedRouteMode,\n} from \"./types\";\n\nexport const RENDER_MODE_DESCRIPTORS: Readonly<\n\tRecord<RenderMode, RenderModeDescriptor>\n> = {\n\tcsr: {\n\t\tmode: \"csr\",\n\t\tlabel: \"Client-Side Rendering\",\n\t\tshortLabel: \"CSR\",\n\t\tdescription:\n\t\t\t\"React renders entirely in the browser. The server sends a minimal HTML shell with a JS bundle. No server required at runtime.\",\n\t\tserverRequired: false,\n\t\tbuildTimeGenerated: false,\n\t\tclientHydration: true,\n\t\troadmap: false,\n\t},\n\tssr: {\n\t\tmode: \"ssr\",\n\t\tlabel: \"Server-Side Rendering\",\n\t\tshortLabel: \"SSR\",\n\t\tdescription:\n\t\t\t\"React renders to HTML on the server per request. The client receives full HTML and then hydrates. Requires a running Node/Bun server.\",\n\t\tserverRequired: true,\n\t\tbuildTimeGenerated: false,\n\t\tclientHydration: true,\n\t\troadmap: true, // Roadmap: v0.2.0\n\t},\n\tssg: {\n\t\tmode: \"ssg\",\n\t\tlabel: \"Static Site Generation\",\n\t\tshortLabel: \"SSG\",\n\t\tdescription:\n\t\t\t\"Pages are fully rendered at build time. Output is static HTML files. No server required at runtime.\",\n\t\tserverRequired: false,\n\t\tbuildTimeGenerated: true,\n\t\tclientHydration: false,\n\t\troadmap: true, // Roadmap: v0.2.0\n\t},\n\tcsg: {\n\t\tmode: \"csg\",\n\t\tlabel: \"Client-Side Generation\",\n\t\tshortLabel: \"CSG\",\n\t\tdescription:\n\t\t\t\"A static shell is generated at build time, data is fetched and rendered on the client. Combines SSG speed with dynamic data.\",\n\t\tserverRequired: false,\n\t\tbuildTimeGenerated: true,\n\t\tclientHydration: true,\n\t\troadmap: true, // Roadmap: v0.2.0\n\t},\n\tspa: {\n\t\tmode: \"spa\",\n\t\tlabel: \"Single Page Application\",\n\t\tshortLabel: \"SPA\",\n\t\tdescription:\n\t\t\t\"A single HTML entry point is served for all routes. React handles all routing client-side. Equivalent to a standard Vite SPA.\",\n\t\tserverRequired: false,\n\t\tbuildTimeGenerated: false,\n\t\tclientHydration: true,\n\t\troadmap: false,\n\t},\n\thybrid: {\n\t\tmode: \"hybrid\",\n\t\tlabel: \"Hybrid Rendering\",\n\t\tshortLabel: \"Hybrid\",\n\t\tdescription:\n\t\t\t\"Different routes use different render modes. Configured via the `render.routes` map in rakta.config.ts. The top-level mode is the fallback.\",\n\t\tserverRequired: false,\n\t\tbuildTimeGenerated: false,\n\t\tclientHydration: true,\n\t\troadmap: false,\n\t},\n};\n\n/**\n * Returns true if the pathname matches a given route pattern.\n * Supports exact paths and simple :param segments (e.g. /blog/:slug).\n */\nfunction pathMatchesPattern(pathname: string, pattern: string): boolean {\n\tif (pattern === pathname) return true;\n\n\tconst patternParts = pattern.split(\"/\");\n\tconst pathParts = pathname.split(\"/\");\n\n\tif (patternParts.length !== pathParts.length) return false;\n\n\tfor (let i = 0; i < patternParts.length; i++) {\n\t\tconst pp = patternParts[i];\n\t\tconst path = pathParts[i];\n\t\tif (pp === undefined || path === undefined) return false;\n\t\tif (pp.startsWith(\":\")) continue; // dynamic segment — always matches\n\t\tif (pp !== path) return false;\n\t}\n\n\treturn true;\n}\n\n/**\n * Resolves the render mode for the given pathname using the provided config.\n * Route-specific overrides take priority. The most specific (longest) matching\n * pattern wins. Falls back to `config.defaultMode`.\n */\nexport function resolveRouteMode(\n\tpathname: string,\n\tconfig: RenderConfig,\n): ResolvedRouteMode {\n\tconst patterns = Object.keys(config.routes).sort(\n\t\t(a, b) => b.length - a.length, // longest pattern first (most specific)\n\t);\n\n\tfor (const pattern of patterns) {\n\t\tconst overrideMode = config.routes[pattern];\n\t\tif (overrideMode !== undefined && pathMatchesPattern(pathname, pattern)) {\n\t\t\treturn {\n\t\t\t\troutePath: pathname,\n\t\t\t\tmode: overrideMode,\n\t\t\t\tsource: \"route-override\",\n\t\t\t};\n\t\t}\n\t}\n\n\treturn {\n\t\troutePath: pathname,\n\t\tmode: config.defaultMode,\n\t\tsource: \"default\",\n\t};\n}\n\nexport function getModeDescriptor(mode: RenderMode): RenderModeDescriptor {\n\treturn RENDER_MODE_DESCRIPTORS[mode];\n}\n\nexport function isRoadmapMode(mode: RenderMode): boolean {\n\treturn RENDER_MODE_DESCRIPTORS[mode].roadmap;\n}\n\nexport function requiresServer(mode: RenderMode): boolean {\n\treturn RENDER_MODE_DESCRIPTORS[mode].serverRequired;\n}\n\nexport function isBuildTimeMode(mode: RenderMode): boolean {\n\treturn RENDER_MODE_DESCRIPTORS[mode].buildTimeGenerated;\n}\n",
|
|
20
|
+
"import { isRoadmapMode } from \"./modes\";\nimport type {\n\tRenderContext,\n\tRenderFailure,\n\tRenderMode,\n\tRenderResult,\n\tRenderSuccess,\n} from \"./types\";\n\nexport interface RendererOptions {\n\treadonly appName: string;\n\treadonly scriptPath: string;\n\treadonly cssPath: string;\n\treadonly lang: string;\n}\n\nfunction buildHtmlShell(options: RendererOptions): string {\n\treturn `\n <!DOCTYPE html>\n <html lang=\"${options.lang}\">\n <head>\n <meta charset=\"UTF-8\" />\n <meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\" />\n <title>\n ${options.appName}\n </title>\n <link rel=\"stylesheet\" href=\"${options.cssPath}\" />\n </head>\n <body>\n <div id=\"rakta-root\"></div>\n <script type=\"module\" src=\"${options.scriptPath}\"></script>\n </body>\n </html>`;\n}\n\nfunction makeSuccess(\n\thtml: string,\n\tmode: RenderMode,\n\trenderMs: number,\n\thttpStatus: number = 200,\n\tfromCache: boolean = false,\n): RenderSuccess {\n\treturn {\n\t\tkind: \"success\",\n\t\thtml,\n\t\tmode,\n\t\thttpStatus,\n\t\tresponseHeaders: { \"Content-Type\": \"text/html; charset=utf-8\" },\n\t\tfromCache,\n\t\trenderMs,\n\t};\n}\n\nfunction makeFailure(\n\treason: string,\n\tmode: RenderMode,\n\thttpStatus: number = 500,\n): RenderFailure {\n\treturn { kind: \"failure\", reason, mode, httpStatus };\n}\n\n/**\n * Render a page using the resolved mode from the context.\n * Roadmap modes (ssr, ssg, csg) fall back to a CSR shell in v0.1.0.\n */\nexport async function render(\n\tcontext: RenderContext,\n\toptions: RendererOptions,\n): Promise<RenderResult> {\n\tconst startMs = Date.now();\n\n\t// Roadmap modes: fall back to CSR shell with a warning\n\tif (isRoadmapMode(context.mode)) {\n\t\tconsole.warn(\n\t\t\t`[Rakta.js] Render mode \"${context.mode}\" is a roadmap feature (v0.2.0). ` +\n\t\t\t\t`Falling back to CSR for: ${context.routePath}`,\n\t\t);\n\t\treturn makeSuccess(buildHtmlShell(options), \"csr\", Date.now() - startMs);\n\t}\n\n\tswitch (context.mode) {\n\t\tcase \"csr\":\n\t\tcase \"spa\":\n\t\t\treturn makeSuccess(\n\t\t\t\tbuildHtmlShell(options),\n\t\t\t\tcontext.mode,\n\t\t\t\tDate.now() - startMs,\n\t\t\t);\n\n\t\tcase \"hybrid\":\n\t\t\t// Hybrid resolution happens upstream in Tide. If it reaches the renderer\n\t\t\t// as hybrid, the route had no specific override - fall back to CSR.\n\t\t\treturn makeSuccess(buildHtmlShell(options), \"csr\", Date.now() - startMs);\n\n\t\tcase \"ssr\":\n\t\tcase \"ssg\":\n\t\tcase \"csg\":\n\t\t\t// These are already caught by isRoadmapMode above, but TypeScript\n\t\t\t// requires an exhaustive switch for the RenderMode union.\n\t\t\treturn makeFailure(\n\t\t\t\t`Render mode \"${context.mode}\" is not yet implemented.`,\n\t\t\t\tcontext.mode,\n\t\t\t\t501,\n\t\t\t);\n\t}\n}\n\nexport function renderNotFound(options: RendererOptions): RenderSuccess {\n\treturn makeSuccess(buildHtmlShell(options), \"csr\", 0, 404);\n}\n\nexport function renderServerError(\n\treason: string,\n\tmode: RenderMode,\n): RenderFailure {\n\treturn makeFailure(reason, mode, 500);\n}\n",
|
|
21
|
+
"import type {\n\tMatchedRoute,\n\tRouteManifestEntry,\n\tRouteSegment,\n} from \"./types.js\";\n\nfunction escapeRegex(text: string): string {\n\treturn text.replace(/[.*+?^${}()|[\\]\\\\]/g, \"\\\\$&\");\n}\n\nfunction buildPatternRegex(segments: RouteSegment[]): {\n\tregex: RegExp;\n\tparamNames: string[];\n} {\n\tconst paramNames: string[] = [];\n\n\tconst parts = segments.map((segment) => {\n\t\tif (segment.isDynamic && segment.paramName) {\n\t\t\tparamNames.push(segment.paramName);\n\t\t\t// Match any non-slash sequence for the param\n\t\t\treturn \"([^/]+)\";\n\t\t}\n\t\treturn escapeRegex(segment.raw);\n\t});\n\n\tconst pattern = parts.length === 0 ? \"\" : `/${parts.join(\"/\")}`;\n\tconst regex = new RegExp(`^${pattern || \"/\"}$`);\n\n\treturn { regex, paramNames };\n}\n\nexport function matchRoute(\n\tpathname: string,\n\troutes: RouteManifestEntry[],\n): MatchedRoute | null {\n\t// Normalize pathname: strip trailing slash unless root\n\tconst normalized =\n\t\tpathname !== \"/\" && pathname.endsWith(\"/\")\n\t\t\t? pathname.slice(0, -1)\n\t\t\t: pathname;\n\n\tfor (const entry of routes) {\n\t\t// Only match pages and api routes\n\t\tif (entry.kind !== \"page\" && entry.kind !== \"api\") continue;\n\n\t\tconst { regex, paramNames } = buildPatternRegex(entry.segments);\n\t\tconst match = regex.exec(normalized);\n\n\t\tif (!match) continue;\n\n\t\tconst params: Record<string, string> = {};\n\t\tparamNames.forEach((name, index) => {\n\t\t\tconst captured = match[index + 1];\n\t\t\tif (captured !== undefined) {\n\t\t\t\tparams[name] = decodeURIComponent(captured);\n\t\t\t}\n\t\t});\n\n\t\treturn { entry, params };\n\t}\n\n\treturn null;\n}\n\nexport function findLayoutsForPathname(\n\tpathname: string,\n\troutes: RouteManifestEntry[],\n): RouteManifestEntry[] {\n\tconst layoutRoutes = routes.filter((route) => route.kind === \"layout\");\n\n\treturn layoutRoutes.filter((layout) => {\n\t\tif (layout.urlPattern === \"/\") return true;\n\t\treturn (\n\t\t\tpathname === layout.urlPattern ||\n\t\t\tpathname.startsWith(`${layout.urlPattern}/`)\n\t\t);\n\t});\n}\n\nexport function findSpecialRoute(\n\tkind: \"loading\" | \"not-found\" | \"error\",\n\tpathname: string,\n\troutes: RouteManifestEntry[],\n): RouteManifestEntry | null {\n\tconst candidates = routes.filter((route) => route.kind === kind);\n\n\t// Find the most specific match (longest matching prefix)\n\tlet best: RouteManifestEntry | null = null;\n\tlet bestLength = -1;\n\n\tfor (const candidate of candidates) {\n\t\tconst prefix = candidate.urlPattern === \"/\" ? \"\" : candidate.urlPattern;\n\t\tif (pathname.startsWith(prefix) && prefix.length > bestLength) {\n\t\t\tbest = candidate;\n\t\t\tbestLength = prefix.length;\n\t\t}\n\t}\n\n\treturn best;\n}\n",
|
|
22
|
+
"import { existsSync, readdirSync, statSync } from \"node:fs\";\nimport { join } from \"node:path\";\nimport { resolveRouteMode } from \"../render/modes\";\nimport type { RenderConfig } from \"../render/types\";\nimport { readManifest } from \"../router/manifest\";\nimport type {\n\tArtifactKind,\n\tForgeBuildArtifact,\n\tForgeInspectReport,\n\tForgeRouteModeEntry,\n} from \"./types\";\n\nexport interface InspectOptions {\n\treadonly outDir: string;\n\treadonly renderConfig: RenderConfig;\n}\n\nfunction detectArtifactKind(filename: string): ArtifactKind {\n\tif (filename === \"route-manifest.json\") return \"manifest\";\n\tif (filename.endsWith(\".css\")) return \"stylesheet\";\n\tif (filename.endsWith(\".js\") || filename.endsWith(\".mjs\")) return \"script\";\n\treturn \"asset\";\n}\n\nfunction formatBytes(bytes: number): string {\n\tif (bytes < 1024) return `${bytes} B`;\n\tif (bytes < 1_048_576) return `${(bytes / 1024).toFixed(1)} KB`;\n\treturn `${(bytes / 1_048_576).toFixed(2)} MB`;\n}\n\nfunction scanDirectory(dirPath: string): ForgeBuildArtifact[] {\n\tif (!existsSync(dirPath)) return [];\n\tconst collected: ForgeBuildArtifact[] = [];\n\n\tfunction walk(current: string): void {\n\t\tconst entries = readdirSync(current, { withFileTypes: true });\n\t\tfor (const entry of entries) {\n\t\t\tconst full = join(current, entry.name);\n\t\t\tif (entry.isDirectory()) {\n\t\t\t\twalk(full);\n\t\t\t} else if (entry.isFile()) {\n\t\t\t\tcollected.push({\n\t\t\t\t\toutputPath: full,\n\t\t\t\t\tsizeBytes: statSync(full).size,\n\t\t\t\t\tkind: detectArtifactKind(entry.name),\n\t\t\t\t});\n\t\t\t}\n\t\t}\n\t}\n\n\twalk(dirPath);\n\treturn collected;\n}\n\nexport function inspectBuild(options: InspectOptions): ForgeInspectReport {\n\tconst artifacts = scanDirectory(options.outDir);\n\tconst manifestPath = join(options.outDir, \"route-manifest.json\");\n\tconst manifest = readManifest(manifestPath);\n\n\tconst emptyManifest = {\n\t\tversion: \"1\" as const,\n\t\tgeneratedAt: new Date().toISOString(),\n\t\troutes: [],\n\t};\n\n\tconst routeModes: ForgeRouteModeEntry[] = (manifest ?? emptyManifest).routes\n\t\t.filter((r) => r.kind === \"page\" || r.kind === \"api\")\n\t\t.map((r) => {\n\t\t\tconst resolved = resolveRouteMode(r.urlPattern, options.renderConfig);\n\t\t\treturn {\n\t\t\t\tpattern: r.urlPattern,\n\t\t\t\tmode: resolved.mode,\n\t\t\t\tsource: resolved.source,\n\t\t\t};\n\t\t});\n\n\treturn {\n\t\tbuildDir: options.outDir,\n\t\tartifacts,\n\t\tmanifest: manifest ?? emptyManifest,\n\t\trouteModes,\n\t\ttotalSizeBytes: artifacts.reduce((sum, a) => sum + a.sizeBytes, 0),\n\t\tinspectedAt: new Date().toISOString(),\n\t};\n}\n\nexport function printInspectReport(report: ForgeInspectReport): void {\n\tconst sep = \"─\".repeat(58);\n\tconsole.log(`\n \\n Rakta.js Forge - Build Inspection\n `);\n\tconsole.log(`\n ${sep}\n `);\n\tconsole.log(`\n Directory: ${report.buildDir}\n `);\n\tconsole.log(`\n Inspected: ${report.inspectedAt}\n `);\n\tconsole.log(`\n Total size: ${formatBytes(report.totalSizeBytes)}\\n\n `);\n\n\tif (report.artifacts.length > 0) {\n\t\tconsole.log(\"Artifacts:\");\n\t\tfor (const artifact of report.artifacts) {\n\t\t\tconst rel = artifact.outputPath\n\t\t\t\t.replace(report.buildDir, \".\")\n\t\t\t\t.replace(/\\\\/g, \"/\");\n\t\t\tconsole.log(`\n [${artifact.kind.padEnd(10)}] \n ${rel.padEnd(38)} \n ${formatBytes(artifact.sizeBytes)}`);\n\t\t}\n\t\tconsole.log(\"\");\n\t}\n\n\tif (report.routeModes.length > 0) {\n\t\tconsole.log(\"Route Render Modes:\");\n\t\tfor (const rm of report.routeModes) {\n\t\t\tconst src = rm.source === \"route-override\" ? \"(override)\" : \"(default) \";\n\t\t\tconsole.log(`\n ${rm.mode.toUpperCase().padEnd(8)} \n ${rm.pattern.padEnd(36)} ${src}`);\n\t\t}\n\t\tconsole.log(\"\");\n\t}\n\n\tconsole.log(`${sep}\\n`);\n}\n",
|
|
23
|
+
"export class HttpResponseError extends Error {\n\treadonly status: number;\n\treadonly statusText: string;\n\treadonly url: string;\n\n\tconstructor(response: Response) {\n\t\tsuper(`HTTP ${response.status} ${response.statusText} - ${response.url}`);\n\n\t\tthis.name = \"HttpResponseError\";\n\t\tthis.status = response.status;\n\t\tthis.statusText = response.statusText;\n\t\tthis.url = response.url;\n\t}\n}\n\nexport class HttpTimeoutError extends Error {\n\treadonly url: string;\n\treadonly timeoutMs: number;\n\n\tconstructor(url: string, timeoutMs: number) {\n\t\tsuper(`Request to ${url} timed out after ${timeoutMs}ms`);\n\n\t\tthis.name = \"HttpTimeoutError\";\n\t\tthis.url = url;\n\t\tthis.timeoutMs = timeoutMs;\n\t}\n}\n\nexport class HttpNetworkError extends Error {\n\treadonly url: string;\n\treadonly originalError: Error;\n\n\tconstructor(url: string, originalError: Error) {\n\t\tsuper(`Network error for ${url}: ${originalError.message}`);\n\n\t\tthis.name = \"HttpNetworkError\";\n\t\tthis.url = url;\n\t\tthis.originalError = originalError;\n\t}\n}\n",
|
|
24
|
+
"import {\n\tHttpNetworkError,\n\tHttpResponseError,\n\tHttpTimeoutError,\n} from \"./errors\";\nimport type {\n\tHttpClientConfig,\n\tHttpMethod,\n\tHttpRequestBody,\n\tHttpRequestConfig,\n\tRequestInterceptorFn,\n\tResponseInterceptorFn,\n} from \"./types\";\n\ntype HttpJsonResponse = HttpRequestBody | string;\n\nfunction buildUrl(\n\tbaseUrl: string,\n\tpath: string,\n\tparams?: HttpRequestConfig[\"params\"],\n): string {\n\tconst base = baseUrl.endsWith(\"/\") ? baseUrl.slice(0, -1) : baseUrl;\n\tconst fullUrl = path.startsWith(\"http\") ? path : `${base}${path}`;\n\tconst parsedUrl = new URL(fullUrl);\n\n\tif (params) {\n\t\tfor (const [key, value] of Object.entries(params)) {\n\t\t\tparsedUrl.searchParams.set(key, String(value));\n\t\t}\n\t}\n\n\treturn parsedUrl.toString();\n}\n\nfunction canSendBody(method: HttpMethod): boolean {\n\treturn method !== \"GET\" && method !== \"HEAD\";\n}\n\nfunction createRequestInit(\n\tmethod: HttpMethod,\n\theaders: Record<string, string>,\n\tbody?: HttpRequestBody,\n): RequestInit {\n\tconst requestInit: RequestInit = {\n\t\tmethod,\n\t\theaders,\n\t};\n\n\tif (body !== undefined && canSendBody(method)) {\n\t\trequestInit.body = JSON.stringify(body);\n\t}\n\n\treturn requestInit;\n}\n\n/**\n * PanturaFetch — Rakta.js built-in type-safe HTTP client.\n *\n * Named after the Pantura (Pantai Utara) highway: fast, reliable, coastal.\n *\n * Usage:\n * const http = createRaktaHttp({ baseUrl: \"http://localhost:4000\" });\n * const users = await http.get<User[]>(\"/users\");\n */\nexport class RaktaHttpClient {\n\tprivate readonly clientConfig: Required<Omit<HttpClientConfig, \"headers\">> & {\n\t\treadonly headers: Record<string, string>;\n\t};\n\n\tprivate readonly requestInterceptors: RequestInterceptorFn[] = [];\n\tprivate readonly responseInterceptors: ResponseInterceptorFn<HttpJsonResponse>[] =\n\t\t[];\n\n\tconstructor(config: HttpClientConfig) {\n\t\tthis.clientConfig = {\n\t\t\tbaseUrl: config.baseUrl,\n\t\t\theaders: config.headers ?? {\n\t\t\t\t\"Content-Type\": \"application/json\",\n\t\t\t},\n\t\t\ttimeout: config.timeout ?? 30_000,\n\t\t};\n\t}\n\n\taddRequestInterceptor(interceptorFn: RequestInterceptorFn): this {\n\t\tthis.requestInterceptors.push(interceptorFn);\n\t\treturn this;\n\t}\n\n\taddResponseInterceptor<TData>(\n\t\tinterceptorFn: ResponseInterceptorFn<TData>,\n\t): this {\n\t\tconst wrappedInterceptor: ResponseInterceptorFn<HttpJsonResponse> = async (\n\t\t\tresponse: Response,\n\t\t\tdata: HttpJsonResponse,\n\t\t): Promise<HttpJsonResponse> => {\n\t\t\treturn (await Promise.resolve(\n\t\t\t\tinterceptorFn(response, data as TData),\n\t\t\t)) as HttpJsonResponse;\n\t\t};\n\n\t\tthis.responseInterceptors.push(wrappedInterceptor);\n\t\treturn this;\n\t}\n\n\tprivate async execute<TData>(\n\t\tmethod: HttpMethod,\n\t\tpath: string,\n\t\tbody?: HttpRequestBody,\n\t\trequestConfig?: HttpRequestConfig,\n\t): Promise<TData> {\n\t\tlet resolvedUrl = buildUrl(\n\t\t\tthis.clientConfig.baseUrl,\n\t\t\tpath,\n\t\t\trequestConfig?.params,\n\t\t);\n\n\t\tlet requestInit = createRequestInit(\n\t\t\tmethod,\n\t\t\t{\n\t\t\t\t...this.clientConfig.headers,\n\t\t\t\t...(requestConfig?.headers ?? {}),\n\t\t\t},\n\t\t\tbody,\n\t\t);\n\n\t\tfor (const interceptorFn of this.requestInterceptors) {\n\t\t\t[resolvedUrl, requestInit] = await Promise.resolve(\n\t\t\t\tinterceptorFn(resolvedUrl, requestInit),\n\t\t\t);\n\t\t}\n\n\t\tconst timeoutMs = requestConfig?.timeout ?? this.clientConfig.timeout;\n\t\tconst abortController = new AbortController();\n\t\tconst timeoutHandle = setTimeout(() => abortController.abort(), timeoutMs);\n\n\t\trequestInit = { ...requestInit, signal: abortController.signal };\n\n\t\tlet response: Response;\n\n\t\ttry {\n\t\t\tresponse = await fetch(resolvedUrl, requestInit);\n\t\t} catch (caughtError) {\n\t\t\tclearTimeout(timeoutHandle);\n\n\t\t\tif (\n\t\t\t\tcaughtError instanceof DOMException &&\n\t\t\t\tcaughtError.name === \"AbortError\"\n\t\t\t) {\n\t\t\t\tthrow new HttpTimeoutError(resolvedUrl, timeoutMs);\n\t\t\t}\n\n\t\t\tthrow new HttpNetworkError(\n\t\t\t\tresolvedUrl,\n\t\t\t\tcaughtError instanceof Error\n\t\t\t\t\t? caughtError\n\t\t\t\t\t: new Error(String(caughtError)),\n\t\t\t);\n\t\t}\n\n\t\tclearTimeout(timeoutHandle);\n\n\t\tif (!response.ok) {\n\t\t\tthrow new HttpResponseError(response);\n\t\t}\n\n\t\tconst contentType = response.headers.get(\"content-type\") ?? \"\";\n\t\tlet responseData: HttpJsonResponse;\n\n\t\tif (contentType.includes(\"application/json\")) {\n\t\t\tresponseData = (await response.json()) as HttpJsonResponse;\n\t\t} else {\n\t\t\tresponseData = await response.text();\n\t\t}\n\n\t\tlet interceptedData: HttpJsonResponse = responseData;\n\n\t\tfor (const interceptorFn of this.responseInterceptors) {\n\t\t\tinterceptedData = await Promise.resolve(\n\t\t\t\tinterceptorFn(response, interceptedData),\n\t\t\t);\n\t\t}\n\n\t\treturn interceptedData as TData;\n\t}\n\n\tget<TData>(path: string, config?: HttpRequestConfig): Promise<TData> {\n\t\treturn this.execute<TData>(\"GET\", path, undefined, config);\n\t}\n\n\tpost<TData>(\n\t\tpath: string,\n\t\tbody?: HttpRequestBody,\n\t\tconfig?: HttpRequestConfig,\n\t): Promise<TData> {\n\t\treturn this.execute<TData>(\"POST\", path, body, config);\n\t}\n\n\tput<TData>(\n\t\tpath: string,\n\t\tbody?: HttpRequestBody,\n\t\tconfig?: HttpRequestConfig,\n\t): Promise<TData> {\n\t\treturn this.execute<TData>(\"PUT\", path, body, config);\n\t}\n\n\tpatch<TData>(\n\t\tpath: string,\n\t\tbody?: HttpRequestBody,\n\t\tconfig?: HttpRequestConfig,\n\t): Promise<TData> {\n\t\treturn this.execute<TData>(\"PATCH\", path, body, config);\n\t}\n\n\tdelete<TData>(path: string, config?: HttpRequestConfig): Promise<TData> {\n\t\treturn this.execute<TData>(\"DELETE\", path, undefined, config);\n\t}\n}\n\n/**\n * Creates a PanturaFetch HTTP client instance.\n *\n * Usage:\n * const http = createRaktaHttp({ baseUrl: \"http://localhost:4000\" });\n * const users = await http.get<User[]>(\"/users\");\n */\nexport function createRaktaHttp(config: HttpClientConfig): RaktaHttpClient {\n\treturn new RaktaHttpClient(config);\n}\n",
|
|
25
|
+
"import type { CacheStrategyOptions } from \"./types\";\n\n/** Builds a versioned cache name, e.g. \"rakta-shrimp-harbor-v1\". */\nexport function buildCacheName(\n\tcacheName: string,\n\tcacheVersion: string,\n): string {\n\tconst sanitizedName = cacheName.trim().toLowerCase().replace(/\\s+/g, \"-\");\n\tconst sanitizedVersion = cacheVersion.trim().toLowerCase();\n\n\treturn `${sanitizedName}-${sanitizedVersion}`;\n}\n\n/** Returns the list of URLs that should be precached, including the offline fallback. */\nexport function resolvePrecacheList(options: CacheStrategyOptions): string[] {\n\tconst uniqueUrls = new Set<string>(options.precacheUrls);\n\tuniqueUrls.add(options.offlineFallbackUrl);\n\n\treturn Array.from(uniqueUrls);\n}\n",
|
|
26
|
+
"import type { ManifestOptions, WebAppManifest } from \"./types\";\n\n/**\n * ShrimpHarbor — generates a web app manifest object for PWA installability.\n * Serialize with JSON.stringify and serve as /manifest.webmanifest.\n */\nexport function generateManifest(options: ManifestOptions): WebAppManifest {\n\tconst manifestObject: WebAppManifest = {\n\t\tname: options.name,\n\t\tshort_name: options.shortName,\n\t\tstart_url: options.startUrl ?? \"/\",\n\t\tscope: options.scope ?? \"/\",\n\t\tdisplay: options.display ?? \"standalone\",\n\t\tbackground_color: options.backgroundColor ?? \"#050505\",\n\t\ttheme_color: options.themeColor ?? \"#dc2626\",\n\t\ticons: options.icons.map((icon) => {\n\t\t\tconst manifestIcon = {\n\t\t\t\tsrc: icon.src,\n\t\t\t\tsizes: icon.sizes,\n\t\t\t\ttype: icon.type,\n\t\t\t};\n\n\t\t\tif (icon.purpose !== undefined) {\n\t\t\t\treturn {\n\t\t\t\t\t...manifestIcon,\n\t\t\t\t\tpurpose: icon.purpose,\n\t\t\t\t};\n\t\t\t}\n\n\t\t\treturn manifestIcon;\n\t\t}),\n\t};\n\n\tif (options.description !== undefined) {\n\t\treturn {\n\t\t\t...manifestObject,\n\t\t\tdescription: options.description,\n\t\t};\n\t}\n\n\treturn manifestObject;\n}\n\n/** Serializes the manifest to a JSON string ready to write to disk or serve. */\nexport function generateManifestJson(options: ManifestOptions): string {\n\treturn JSON.stringify(generateManifest(options), undefined, 2);\n}\n\n/** Creates a Bun/Tide-compatible request handler that serves the manifest. */\nexport function createManifestHandler(\n\toptions: ManifestOptions,\n): () => Response {\n\treturn () => {\n\t\tconst manifestJson = generateManifestJson(options);\n\n\t\treturn new Response(manifestJson, {\n\t\t\tstatus: 200,\n\t\t\theaders: {\n\t\t\t\t\"Content-Type\": \"application/manifest+json; charset=utf-8\",\n\t\t\t\t\"Cache-Control\": \"public, max-age=3600\",\n\t\t\t},\n\t\t});\n\t};\n}\n",
|
|
27
|
+
"import { buildCacheName, resolvePrecacheList } from \"./cache\";\nimport type { ServiceWorkerOptions } from \"./types\";\n\nfunction toJsStringArray(values: readonly string[]): string {\n\treturn `[${values.map((value) => JSON.stringify(value)).join(\", \")}]`;\n}\n\n/**\n * ShrimpHarbor — generates the source text of a service worker file\n * implementing a cache-first strategy with an offline fallback page.\n *\n * Write the returned string to public/sw.js in the generated app.\n * This function only produces text; it does not touch the filesystem\n * or any browser-only APIs, so it is safe to call at build time.\n */\nexport function generateServiceWorkerSource(\n\toptions: ServiceWorkerOptions,\n): string {\n\tconst cacheName = buildCacheName(options.cacheName, options.cacheVersion);\n\tconst precacheList = resolvePrecacheList(options);\n\tconst offlineFallbackUrl = options.offlineFallbackUrl;\n\n\treturn `// Generated by Rakta.js ShrimpHarbor - do not edit manually.\n// Re-run \"bun rakta pwa:generate\" to regenerate this file.\n\nconst CACHE_NAME = ${JSON.stringify(cacheName)};\nconst OFFLINE_FALLBACK_URL = ${JSON.stringify(offlineFallbackUrl)};\nconst PRECACHE_URLS = ${toJsStringArray(precacheList)};\n\nself.addEventListener(\"install\", (installEvent) => {\n installEvent.waitUntil(\n caches.open(CACHE_NAME).then((cache) => cache.addAll(PRECACHE_URLS)),\n );\n self.skipWaiting();\n});\n\nself.addEventListener(\"activate\", (activateEvent) => {\n activateEvent.waitUntil(\n caches.keys().then((cacheKeys) =>\n Promise.all(\n cacheKeys\n .filter((cacheKey) => cacheKey !== CACHE_NAME)\n .map((staleCacheKey) => caches.delete(staleCacheKey)),\n ),\n ),\n );\n self.clients.claim();\n});\n\nself.addEventListener(\"fetch\", (fetchEvent) => {\n if (fetchEvent.request.method !== \"GET\") {\n return;\n }\n\n fetchEvent.respondWith(\n caches.match(fetchEvent.request).then((cachedResponse) => {\n if (cachedResponse) {\n return cachedResponse;\n }\n\n return fetch(fetchEvent.request)\n .then((networkResponse) => {\n const responseClone = networkResponse.clone();\n caches\n .open(CACHE_NAME)\n .then((cache) => cache.put(fetchEvent.request, responseClone));\n return networkResponse;\n })\n .catch(() => {\n if (fetchEvent.request.mode === \"navigate\") {\n return caches.match(OFFLINE_FALLBACK_URL);\n }\n\n return caches.match(fetchEvent.request);\n });\n }),\n );\n});\n`;\n}\n",
|
|
28
|
+
"import type { RouterClient, RouterDefinition, RpcEnvelope } from \"./types\";\n\nexport interface RaktaClientConfig {\n\treadonly baseUrl: string;\n\treadonly headers?: Record<string, string>;\n\treadonly timeout?: number;\n}\n\nexport interface RaktaRpcErrorDetail {\n\treadonly path: ReadonlyArray<string>;\n\treadonly message: string;\n}\n\nexport class RaktaRpcError extends Error {\n\treadonly code: string;\n\treadonly details?: ReadonlyArray<RaktaRpcErrorDetail>;\n\n\tconstructor(\n\t\tmessage: string,\n\t\tcode: string,\n\t\tdetails?: ReadonlyArray<RaktaRpcErrorDetail>,\n\t) {\n\t\tsuper(message);\n\n\t\tthis.name = \"RaktaRpcError\";\n\t\tthis.code = code;\n\n\t\tif (details !== undefined) {\n\t\t\tthis.details = details;\n\t\t}\n\t}\n}\n\nasync function callProcedure<TInput, TOutput>(\n\tclientConfig: RaktaClientConfig,\n\tprocedureName: string,\n\tprocedureInput: TInput,\n): Promise<TOutput> {\n\tconst abortController = new AbortController();\n\tconst timeoutMs = clientConfig.timeout ?? 30_000;\n\tconst timeoutHandle = setTimeout(() => abortController.abort(), timeoutMs);\n\n\tlet response: Response;\n\n\ttry {\n\t\tresponse = await fetch(clientConfig.baseUrl, {\n\t\t\tmethod: \"POST\",\n\t\t\theaders: {\n\t\t\t\t\"Content-Type\": \"application/json\",\n\t\t\t\t...(clientConfig.headers ?? {}),\n\t\t\t},\n\t\t\tbody: JSON.stringify({\n\t\t\t\tprocedure: procedureName,\n\t\t\t\tinput: procedureInput,\n\t\t\t}),\n\t\t\tsignal: abortController.signal,\n\t\t});\n\t} finally {\n\t\tclearTimeout(timeoutHandle);\n\t}\n\n\tconst responseEnvelope = (await response.json()) as RpcEnvelope<TOutput>;\n\n\tif (!responseEnvelope.ok) {\n\t\tthrow new RaktaRpcError(\n\t\t\tresponseEnvelope.error,\n\t\t\tresponseEnvelope.code,\n\t\t\tresponseEnvelope.details,\n\t\t);\n\t}\n\n\treturn responseEnvelope.data;\n}\n\n/**\n * CarubanWire — Creates a type-safe RPC client.\n *\n * Usage:\n * const api = createRaktaClient<AppRouter>({ baseUrl: \"http://localhost:4000/rpc\" });\n * const result = await api.hello.query({ name: \"Rakta\" });\n */\nexport function createRaktaClient<TRouter extends RouterDefinition>(\n\tclientConfig: RaktaClientConfig,\n): RouterClient<TRouter> {\n\treturn new Proxy({} as RouterClient<TRouter>, {\n\t\tget(_target, procedureName: string) {\n\t\t\treturn {\n\t\t\t\tquery: (procedureInput: unknown) =>\n\t\t\t\t\tcallProcedure(clientConfig, procedureName, procedureInput),\n\t\t\t\tmutate: (procedureInput: unknown) =>\n\t\t\t\t\tcallProcedure(clientConfig, procedureName, procedureInput),\n\t\t\t};\n\t\t},\n\t});\n}\n",
|
|
29
|
+
"import type { RaktaType } from \"../schema/types\";\nimport type { ProcedureDefinition, ProcedureKind } from \"./types\";\n\n/**\n * CarubanWire — Fluent builder for a single type-safe RPC procedure.\n *\n * Usage:\n * publicProcedure\n * .input(object({ name: string().min(1) }))\n * .query(async ({ input }) => ({ message: `Hello ${input.name}` }))\n */\nexport class ProcedureBuilder<TInput = void> {\n\tprivate readonly inputSchema?: RaktaType<TInput>;\n\n\tconstructor(inputSchema?: RaktaType<TInput>) {\n\t\tif (inputSchema !== undefined) {\n\t\t\tthis.inputSchema = inputSchema;\n\t\t}\n\t}\n\n\t/** Attach an input schema. Returns a new builder with TInput typed. */\n\tinput<TNewInput>(schema: RaktaType<TNewInput>): ProcedureBuilder<TNewInput> {\n\t\treturn new ProcedureBuilder<TNewInput>(schema);\n\t}\n\n\t/** Define a read procedure (CarubanWire query). */\n\tquery<TOutput>(\n\t\thandler: (ctx: { readonly input: TInput }) => Promise<TOutput>,\n\t): ProcedureDefinition<TInput, TOutput> {\n\t\treturn this.build(\"query\", handler);\n\t}\n\n\t/** Define a write procedure (CarubanWire mutation). */\n\tmutation<TOutput>(\n\t\thandler: (ctx: { readonly input: TInput }) => Promise<TOutput>,\n\t): ProcedureDefinition<TInput, TOutput> {\n\t\treturn this.build(\"mutation\", handler);\n\t}\n\n\tprivate build<TOutput>(\n\t\tkind: ProcedureKind,\n\t\thandler: (ctx: { readonly input: TInput }) => Promise<TOutput>,\n\t): ProcedureDefinition<TInput, TOutput> {\n\t\tif (this.inputSchema !== undefined) {\n\t\t\treturn {\n\t\t\t\tkind,\n\t\t\t\tinputSchema: this.inputSchema,\n\t\t\t\thandler,\n\t\t\t};\n\t\t}\n\n\t\treturn {\n\t\t\tkind,\n\t\t\thandler,\n\t\t};\n\t}\n}\n\n/** The base public procedure builder. Chain .input() and .query()/.mutation() from here. */\nexport const publicProcedure = new ProcedureBuilder<void>();\n",
|
|
30
|
+
"export interface ValidationError {\n\treadonly path: ReadonlyArray<string>;\n\treadonly message: string;\n\treadonly code: string;\n}\n\nexport interface ParseSuccess<TOutput> {\n\treadonly kind: \"success\";\n\treadonly data: TOutput;\n}\n\nexport interface ParseFailure {\n\treadonly kind: \"failure\";\n\treadonly errors: ReadonlyArray<ValidationError>;\n}\n\nexport type ParseResult<TOutput> = ParseSuccess<TOutput> | ParseFailure;\n\nexport class RaktaSchemaError extends Error {\n\treadonly errors: ReadonlyArray<ValidationError>;\n\n\tconstructor(errors: ReadonlyArray<ValidationError>) {\n\t\tconst first = errors[0];\n\n\t\tconst prefix = first\n\t\t\t? `[${first.path.join(\".\") || \"root\"}] ${first.message}`\n\t\t\t: \"Validation failed\";\n\n\t\tsuper(\n\t\t\t`Rakta Schema: ${prefix}${\n\t\t\t\terrors.length > 1 ? ` (and ${errors.length - 1} more)` : \"\"\n\t\t\t}`,\n\t\t);\n\n\t\tthis.name = \"RaktaSchemaError\";\n\t\tthis.errors = errors;\n\t}\n}\n\nexport function prefixErrors(\n\terrors: ReadonlyArray<ValidationError>,\n\tkey: string,\n): ValidationError[] {\n\treturn errors.map((error) => ({\n\t\t...error,\n\t\tpath: [key, ...error.path],\n\t}));\n}\n\nexport const preFixErrors = prefixErrors;\n",
|
|
31
|
+
"import { RaktaSchemaError } from \"../schema/errors\";\nimport type { RouterDefinition, RpcEnvelope, RpcPayload } from \"./types\";\n\n/**\n * CarubanWire - Creates a Rakta RPC router from a map of procedure definitions.\n * The return value is typed as `TRouter` so TypeScript can infer procedure types.\n */\nexport function createRaktaRouter<TRouter extends RouterDefinition>(\n\tprocedures: TRouter,\n): TRouter {\n\treturn procedures;\n}\n\n/**\n * Creates an HTTP request handler for the given router.\n * Mount at your chosen base path, e.g. POST /rpc\n */\nexport function createRpcHandler<TRouter extends RouterDefinition>(\n\trouter: TRouter,\n): (request: Request) => Promise<Response> {\n\treturn async (request: Request): Promise<Response> => {\n\t\tif (request.method !== \"POST\") {\n\t\t\treturn buildJsonResponse<string>(\n\t\t\t\t{\n\t\t\t\t\tok: false,\n\t\t\t\t\terror: \"Only POST requests are accepted\",\n\t\t\t\t\tcode: \"method_not_allowed\",\n\t\t\t\t},\n\t\t\t\t405,\n\t\t\t);\n\t\t}\n\n\t\tlet rpcPayload: RpcPayload;\n\n\t\ttry {\n\t\t\trpcPayload = (await request.json()) as RpcPayload;\n\t\t} catch {\n\t\t\treturn buildJsonResponse<string>(\n\t\t\t\t{ ok: false, error: \"Invalid JSON body\", code: \"parse_error\" },\n\t\t\t\t400,\n\t\t\t);\n\t\t}\n\n\t\tif (typeof rpcPayload.procedure !== \"string\") {\n\t\t\treturn buildJsonResponse<string>(\n\t\t\t\t{\n\t\t\t\t\tok: false,\n\t\t\t\t\terror: \"Missing procedure name\",\n\t\t\t\t\tcode: \"invalid_request\",\n\t\t\t\t},\n\t\t\t\t400,\n\t\t\t);\n\t\t}\n\n\t\tconst selectedProcedure = router[rpcPayload.procedure];\n\n\t\tif (selectedProcedure === undefined) {\n\t\t\treturn buildJsonResponse<string>(\n\t\t\t\t{\n\t\t\t\t\tok: false,\n\t\t\t\t\terror: `Procedure \"${rpcPayload.procedure}\" not found`,\n\t\t\t\t\tcode: \"not_found\",\n\t\t\t\t},\n\t\t\t\t404,\n\t\t\t);\n\t\t}\n\n\t\tlet validatedInput: unknown = rpcPayload.input;\n\n\t\tif (selectedProcedure.inputSchema !== undefined) {\n\t\t\tconst validationErrors = selectedProcedure.inputSchema._run(\n\t\t\t\trpcPayload.input,\n\t\t\t);\n\n\t\t\tif (validationErrors.length > 0) {\n\t\t\t\treturn buildJsonResponse<string>(\n\t\t\t\t\t{\n\t\t\t\t\t\tok: false,\n\t\t\t\t\t\terror: \"Input validation failed\",\n\t\t\t\t\t\tcode: \"validation_error\",\n\t\t\t\t\t\tdetails: validationErrors.map((validationError) => ({\n\t\t\t\t\t\t\tpath: validationError.path,\n\t\t\t\t\t\t\tmessage: validationError.message,\n\t\t\t\t\t\t})),\n\t\t\t\t\t},\n\t\t\t\t\t422,\n\t\t\t\t);\n\t\t\t}\n\n\t\t\tvalidatedInput = selectedProcedure.inputSchema.parse(rpcPayload.input);\n\t\t}\n\n\t\ttry {\n\t\t\tconst procedureOutput = await selectedProcedure.handler({\n\t\t\t\tinput: validatedInput,\n\t\t\t});\n\n\t\t\treturn buildJsonResponse({ ok: true, data: procedureOutput }, 200);\n\t\t} catch (caughtError) {\n\t\t\tif (caughtError instanceof RaktaSchemaError) {\n\t\t\t\treturn buildJsonResponse<string>(\n\t\t\t\t\t{\n\t\t\t\t\t\tok: false,\n\t\t\t\t\t\terror: caughtError.message,\n\t\t\t\t\t\tcode: \"schema_error\",\n\t\t\t\t\t},\n\t\t\t\t\t422,\n\t\t\t\t);\n\t\t\t}\n\n\t\t\tconst errorMessage =\n\t\t\t\tcaughtError instanceof Error\n\t\t\t\t\t? caughtError.message\n\t\t\t\t\t: \"Internal server error\";\n\n\t\t\treturn buildJsonResponse<string>(\n\t\t\t\t{ ok: false, error: errorMessage, code: \"internal_error\" },\n\t\t\t\t500,\n\t\t\t);\n\t\t}\n\t};\n}\n\nfunction buildJsonResponse<TData>(\n\tresponseEnvelope: RpcEnvelope<TData>,\n\tstatusCode: number,\n): Response {\n\treturn new Response(JSON.stringify(responseEnvelope), {\n\t\tstatus: statusCode,\n\t\theaders: { \"Content-Type\": \"application/json; charset=utf-8\" },\n\t});\n}\n",
|
|
32
|
+
"import type { ParseResult, ValidationError } from \"./errors\";\nimport { RaktaSchemaError } from \"./errors\";\n\n/** Extracts the output type from any RaktaType. */\nexport type Infer<TSchema> =\n\tTSchema extends RaktaType<infer TOutput> ? TOutput : never;\n\n/** Base class for all Rakta Schema validators. */\nexport abstract class RaktaType<TOutput> {\n\t/** Internal validation — returns errors array (empty = valid). */\n\tabstract _run(value: unknown): ReadonlyArray<ValidationError>;\n\n\t/**\n\t * Validates `value` and returns `TOutput`.\n\t * Throws `RaktaSchemaError` if validation fails.\n\t */\n\tparse(value: unknown): TOutput {\n\t\tconst result = this.safeParse(value);\n\n\t\tif (result.kind === \"failure\") {\n\t\t\tthrow new RaktaSchemaError(result.errors);\n\t\t}\n\n\t\treturn result.data;\n\t}\n\n\t/**\n\t * Validates `value` and returns a discriminated union result.\n\t * Never throws.\n\t */\n\tsafeParse(value: unknown): ParseResult<TOutput> {\n\t\tconst errors = this._run(value);\n\n\t\tif (errors.length > 0) {\n\t\t\treturn {\n\t\t\t\tkind: \"failure\",\n\t\t\t\terrors,\n\t\t\t};\n\t\t}\n\n\t\treturn {\n\t\t\tkind: \"success\",\n\t\t\tdata: value as TOutput,\n\t\t};\n\t}\n\n\t/** Wraps this schema in an optional wrapper. */\n\toptional(): OptionalType<TOutput> {\n\t\treturn new OptionalType(this);\n\t}\n}\n\n/** Wraps any RaktaType to make it accept missing values. */\nexport class OptionalType<TOutput> extends RaktaType<TOutput | undefined> {\n\tprivate readonly inner: RaktaType<TOutput>;\n\n\tconstructor(inner: RaktaType<TOutput>) {\n\t\tsuper();\n\t\tthis.inner = inner;\n\t}\n\n\t_run(value: unknown): ReadonlyArray<ValidationError> {\n\t\tif (typeof value === \"undefined\") {\n\t\t\treturn [];\n\t\t}\n\n\t\treturn this.inner._run(value);\n\t}\n}\n",
|
|
33
|
+
"import type { ValidationError } from \"./errors\";\nimport { type Infer, RaktaType } from \"./types\";\n\nexport class ArrayType<TItem extends RaktaType<unknown>> extends RaktaType<\n\tArray<Infer<TItem>>\n> {\n\tprivate readonly itemSchema: TItem;\n\tprivate readonly minLength?: number;\n\tprivate readonly maxLength?: number;\n\n\tconstructor(itemSchema: TItem, minLength?: number, maxLength?: number) {\n\t\tsuper();\n\n\t\tthis.itemSchema = itemSchema;\n\n\t\tif (typeof minLength === \"number\") {\n\t\t\tthis.minLength = minLength;\n\t\t}\n\n\t\tif (typeof maxLength === \"number\") {\n\t\t\tthis.maxLength = maxLength;\n\t\t}\n\t}\n\n\tprivate clone(minLength?: number, maxLength?: number): ArrayType<TItem> {\n\t\treturn new ArrayType(this.itemSchema, minLength, maxLength);\n\t}\n\n\tmin(length: number): ArrayType<TItem> {\n\t\treturn this.clone(length, this.maxLength);\n\t}\n\n\tmax(length: number): ArrayType<TItem> {\n\t\treturn this.clone(this.minLength, length);\n\t}\n\n\tnonempty(): ArrayType<TItem> {\n\t\treturn this.min(1);\n\t}\n\n\t_run(value: unknown): ReadonlyArray<ValidationError> {\n\t\tif (!Array.isArray(value)) {\n\t\t\treturn [\n\t\t\t\t{\n\t\t\t\t\tpath: [],\n\t\t\t\t\tmessage: \"Expected an array\",\n\t\t\t\t\tcode: \"invalid_type\",\n\t\t\t\t},\n\t\t\t];\n\t\t}\n\n\t\tconst errors: ValidationError[] = [];\n\n\t\tif (typeof this.minLength === \"number\" && value.length < this.minLength) {\n\t\t\terrors.push({\n\t\t\t\tpath: [],\n\t\t\t\tmessage: `Array must contain at least ${this.minLength} item(s)`,\n\t\t\t\tcode: \"too_small\",\n\t\t\t});\n\t\t}\n\n\t\tif (typeof this.maxLength === \"number\" && value.length > this.maxLength) {\n\t\t\terrors.push({\n\t\t\t\tpath: [],\n\t\t\t\tmessage: `Array must contain at most ${this.maxLength} item(s)`,\n\t\t\t\tcode: \"too_big\",\n\t\t\t});\n\t\t}\n\n\t\tfor (let index = 0; index < value.length; index += 1) {\n\t\t\tconst itemValue = value[index];\n\t\t\tconst itemErrors = this.itemSchema._run(itemValue);\n\n\t\t\terrors.push(\n\t\t\t\t...itemErrors.map((error: ValidationError) => ({\n\t\t\t\t\t...error,\n\t\t\t\t\tpath: [String(index), ...error.path],\n\t\t\t\t})),\n\t\t\t);\n\t\t}\n\n\t\treturn errors;\n\t}\n}\n\nexport function array<TItem extends RaktaType<unknown>>(\n\titemSchema: TItem,\n): ArrayType<TItem> {\n\treturn new ArrayType(itemSchema);\n}\n",
|
|
34
|
+
"import type { ValidationError } from \"./errors\";\nimport { RaktaType } from \"./types\";\n\nexport class BooleanType extends RaktaType<boolean> {\n\t_run(value: unknown): ReadonlyArray<ValidationError> {\n\t\tif (typeof value !== \"boolean\") {\n\t\t\treturn [\n\t\t\t\t{\n\t\t\t\t\tpath: [],\n\t\t\t\t\tmessage: \"Expected a boolean\",\n\t\t\t\t\tcode: \"invalid_type\",\n\t\t\t\t},\n\t\t\t];\n\t\t}\n\n\t\treturn [];\n\t}\n}\n\nexport function boolean(): BooleanType {\n\treturn new BooleanType();\n}\n",
|
|
35
|
+
"import type { ValidationError } from \"./errors\";\nimport { RaktaType } from \"./types\";\n\ntype NumberRule = (value: number) => ValidationError | undefined;\n\nexport class NumberType extends RaktaType<number> {\n\tprivate readonly rules: ReadonlyArray<NumberRule>;\n\n\tconstructor(rules: ReadonlyArray<NumberRule> = []) {\n\t\tsuper();\n\t\tthis.rules = rules;\n\t}\n\n\tprivate addRule(rule: NumberRule): NumberType {\n\t\treturn new NumberType([...this.rules, rule]);\n\t}\n\n\t_run(value: unknown): ReadonlyArray<ValidationError> {\n\t\tif (typeof value !== \"number\" || Number.isNaN(value)) {\n\t\t\treturn [\n\t\t\t\t{\n\t\t\t\t\tpath: [],\n\t\t\t\t\tmessage: \"Expected a number\",\n\t\t\t\t\tcode: \"invalid_type\",\n\t\t\t\t},\n\t\t\t];\n\t\t}\n\n\t\tconst errors: ValidationError[] = [];\n\n\t\tfor (const rule of this.rules) {\n\t\t\tconst result = rule(value);\n\n\t\t\tif (result) {\n\t\t\t\terrors.push(result);\n\t\t\t}\n\t\t}\n\n\t\treturn errors;\n\t}\n\n\tmin(threshold: number): NumberType {\n\t\treturn this.addRule((value: number): ValidationError | undefined =>\n\t\t\tvalue < threshold\n\t\t\t\t? {\n\t\t\t\t\t\tpath: [],\n\t\t\t\t\t\tmessage: `Must be at least ${threshold}`,\n\t\t\t\t\t\tcode: \"too_small\",\n\t\t\t\t\t}\n\t\t\t\t: undefined,\n\t\t);\n\t}\n\n\tmax(threshold: number): NumberType {\n\t\treturn this.addRule((value: number): ValidationError | undefined =>\n\t\t\tvalue > threshold\n\t\t\t\t? {\n\t\t\t\t\t\tpath: [],\n\t\t\t\t\t\tmessage: `Must be at most ${threshold}`,\n\t\t\t\t\t\tcode: \"too_big\",\n\t\t\t\t\t}\n\t\t\t\t: undefined,\n\t\t);\n\t}\n\n\tint(): NumberType {\n\t\treturn this.addRule((value: number): ValidationError | undefined =>\n\t\t\t!Number.isInteger(value)\n\t\t\t\t? {\n\t\t\t\t\t\tpath: [],\n\t\t\t\t\t\tmessage: \"Expected an integer\",\n\t\t\t\t\t\tcode: \"not_integer\",\n\t\t\t\t\t}\n\t\t\t\t: undefined,\n\t\t);\n\t}\n\n\tpositive(): NumberType {\n\t\treturn this.addRule((value: number): ValidationError | undefined =>\n\t\t\tvalue <= 0\n\t\t\t\t? {\n\t\t\t\t\t\tpath: [],\n\t\t\t\t\t\tmessage: \"Must be a positive number\",\n\t\t\t\t\t\tcode: \"not_positive\",\n\t\t\t\t\t}\n\t\t\t\t: undefined,\n\t\t);\n\t}\n\n\tnonnegative(): NumberType {\n\t\treturn this.addRule((value: number): ValidationError | undefined =>\n\t\t\tvalue < 0\n\t\t\t\t? {\n\t\t\t\t\t\tpath: [],\n\t\t\t\t\t\tmessage: \"Must be zero or positive\",\n\t\t\t\t\t\tcode: \"not_nonnegative\",\n\t\t\t\t\t}\n\t\t\t\t: undefined,\n\t\t);\n\t}\n}\n\nexport function number(): NumberType {\n\treturn new NumberType();\n}\n",
|
|
36
|
+
"import type { ValidationError } from \"./errors\";\nimport { prefixErrors } from \"./errors\";\nimport { type Infer, RaktaType } from \"./types\";\n\nexport type ShapeRecord = Record<string, RaktaType<unknown>>;\n\nexport type InferShape<TShape extends ShapeRecord> = {\n\t[K in keyof TShape]: Infer<TShape[K]>;\n};\n\nexport class ObjectType<TShape extends ShapeRecord> extends RaktaType<\n\tInferShape<TShape>\n> {\n\tprivate readonly shape: TShape;\n\n\tconstructor(shape: TShape) {\n\t\tsuper();\n\t\tthis.shape = shape;\n\t}\n\n\t_run(value: unknown): ReadonlyArray<ValidationError> {\n\t\tif (typeof value !== \"object\" || value === null || Array.isArray(value)) {\n\t\t\treturn [\n\t\t\t\t{\n\t\t\t\t\tpath: [],\n\t\t\t\t\tmessage: \"Expected an object\",\n\t\t\t\t\tcode: \"invalid_type\",\n\t\t\t\t},\n\t\t\t];\n\t\t}\n\n\t\tconst errors: ValidationError[] = [];\n\t\tconst record = value as Record<string, unknown>;\n\n\t\tfor (const key of Object.keys(this.shape)) {\n\t\t\tconst fieldSchema = this.shape[key];\n\n\t\t\tif (typeof fieldSchema === \"undefined\") {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\tconst fieldValue = record[key];\n\t\t\tconst fieldErrors = fieldSchema._run(fieldValue);\n\n\t\t\terrors.push(...prefixErrors(fieldErrors, key));\n\t\t}\n\n\t\treturn errors;\n\t}\n\n\t/** Merge additional fields into this schema. */\n\textend<TExtension extends ShapeRecord>(\n\t\textension: TExtension,\n\t): ObjectType<TShape & TExtension> {\n\t\treturn new ObjectType({\n\t\t\t...this.shape,\n\t\t\t...extension,\n\t\t});\n\t}\n\n\t/** Create a new schema with only the specified keys. */\n\tpick<TKey extends keyof TShape>(\n\t\tkeys: ReadonlyArray<TKey>,\n\t): ObjectType<Pick<TShape, TKey>> {\n\t\tconst picked = {} as Pick<TShape, TKey>;\n\n\t\tfor (const key of keys) {\n\t\t\tif (key in this.shape) {\n\t\t\t\tpicked[key] = this.shape[key];\n\t\t\t}\n\t\t}\n\n\t\treturn new ObjectType(picked);\n\t}\n\n\t/** Create a new schema omitting the specified keys. */\n\tomit<TKey extends keyof TShape>(\n\t\tkeys: ReadonlyArray<TKey>,\n\t): ObjectType<Omit<TShape, TKey>> {\n\t\tconst result = { ...this.shape };\n\n\t\tfor (const key of keys) {\n\t\t\tdelete result[key];\n\t\t}\n\n\t\treturn new ObjectType(result);\n\t}\n}\n\nexport function object<TShape extends ShapeRecord>(\n\tshape: TShape,\n): ObjectType<TShape> {\n\treturn new ObjectType(shape);\n}\n",
|
|
37
|
+
"import type { ValidationError } from \"./errors\";\nimport { RaktaType } from \"./types\";\n\nconst EMAIL_PATTERN = /^[^\\s@]+@[^\\s@]+\\.[^\\s@]{2,}$/;\n\nconst URL_PATTERN = /^https?:\\/\\/[^\\s$.?#].[^\\s]*$/i;\n\ntype StringRule = (value: string) => ReadonlyArray<ValidationError>;\n\nexport class StringType extends RaktaType<string> {\n\tprivate readonly rules: ReadonlyArray<StringRule>;\n\n\tconstructor(rules: ReadonlyArray<StringRule> = []) {\n\t\tsuper();\n\t\tthis.rules = rules;\n\t}\n\n\tprivate addRule(rule: StringRule): StringType {\n\t\treturn new StringType([...this.rules, rule]);\n\t}\n\n\t_run(value: unknown): ReadonlyArray<ValidationError> {\n\t\tif (typeof value !== \"string\") {\n\t\t\treturn [\n\t\t\t\t{\n\t\t\t\t\tpath: [],\n\t\t\t\t\tmessage: \"Expected a string\",\n\t\t\t\t\tcode: \"invalid_type\",\n\t\t\t\t},\n\t\t\t];\n\t\t}\n\n\t\tconst errors: ValidationError[] = [];\n\n\t\tfor (const rule of this.rules) {\n\t\t\terrors.push(...rule(value));\n\t\t}\n\n\t\treturn errors;\n\t}\n\n\tmin(length: number): StringType {\n\t\treturn this.addRule((value: string): ReadonlyArray<ValidationError> => {\n\t\t\tif (value.length >= length) {\n\t\t\t\treturn [];\n\t\t\t}\n\n\t\t\treturn [\n\t\t\t\t{\n\t\t\t\t\tpath: [],\n\t\t\t\t\tmessage: `Must be at least ${length} character(s)`,\n\t\t\t\t\tcode: \"too_small\",\n\t\t\t\t},\n\t\t\t];\n\t\t});\n\t}\n\n\tmax(length: number): StringType {\n\t\treturn this.addRule((value: string): ReadonlyArray<ValidationError> => {\n\t\t\tif (value.length <= length) {\n\t\t\t\treturn [];\n\t\t\t}\n\n\t\t\treturn [\n\t\t\t\t{\n\t\t\t\t\tpath: [],\n\t\t\t\t\tmessage: `Must be at most ${length} character(s)`,\n\t\t\t\t\tcode: \"too_big\",\n\t\t\t\t},\n\t\t\t];\n\t\t});\n\t}\n\n\temail(): StringType {\n\t\treturn this.addRule((value: string): ReadonlyArray<ValidationError> => {\n\t\t\tif (EMAIL_PATTERN.test(value)) {\n\t\t\t\treturn [];\n\t\t\t}\n\n\t\t\treturn [\n\t\t\t\t{\n\t\t\t\t\tpath: [],\n\t\t\t\t\tmessage: \"Invalid email address\",\n\t\t\t\t\tcode: \"invalid_email\",\n\t\t\t\t},\n\t\t\t];\n\t\t});\n\t}\n\n\turl(): StringType {\n\t\treturn this.addRule((value: string): ReadonlyArray<ValidationError> => {\n\t\t\tif (URL_PATTERN.test(value)) {\n\t\t\t\treturn [];\n\t\t\t}\n\n\t\t\treturn [\n\t\t\t\t{\n\t\t\t\t\tpath: [],\n\t\t\t\t\tmessage: \"Invalid URL\",\n\t\t\t\t\tcode: \"invalid_url\",\n\t\t\t\t},\n\t\t\t];\n\t\t});\n\t}\n\n\tregex(pattern: RegExp, customMessage?: string): StringType {\n\t\treturn this.addRule((value: string): ReadonlyArray<ValidationError> => {\n\t\t\tif (pattern.test(value)) {\n\t\t\t\treturn [];\n\t\t\t}\n\n\t\t\treturn [\n\t\t\t\t{\n\t\t\t\t\tpath: [],\n\t\t\t\t\tmessage:\n\t\t\t\t\t\tcustomMessage ?? `Did not match pattern ${pattern.toString()}`,\n\t\t\t\t\tcode: \"invalid_pattern\",\n\t\t\t\t},\n\t\t\t];\n\t\t});\n\t}\n\n\tnonempty(): StringType {\n\t\treturn this.min(1);\n\t}\n}\n\nexport function string(): StringType {\n\treturn new StringType();\n}\n",
|
|
38
|
+
"export interface OpenGraphImage {\n\turl: string;\n\twidth?: number;\n\theight?: number;\n\talt?: string;\n\ttype?: string;\n}\n\nexport interface OpenGraph {\n\ttype?: \"website\" | \"article\" | \"book\" | \"profile\";\n\ttitle?: string;\n\tdescription?: string;\n\turl?: string;\n\tsiteName?: string;\n\timages?: OpenGraphImage[];\n\tlocale?: string;\n\taudio?: string;\n\tvideo?: string;\n\tdeterminer?: string;\n\tcountryName?: string;\n}\n\nexport interface TwitterCard {\n\tcard?: \"summary\" | \"summary_large_image\" | \"app\" | \"player\";\n\tsite?: string;\n\tcreator?: string;\n\ttitle?: string;\n\tdescription?: string;\n\timage?: string;\n\timageAlt?: string;\n}\n\nexport type JsonLdPrimitive = string | number | boolean;\n\nexport type JsonLdValue =\n\t| JsonLdPrimitive\n\t| JsonLdObject\n\t| readonly JsonLdValue[];\n\nexport interface JsonLdObject {\n\treadonly [key: string]: JsonLdValue;\n}\n\nexport interface JsonLdGraph extends JsonLdObject {\n\t\"@type\": string;\n}\n\nexport interface JsonLd extends JsonLdObject {\n\t\"@context\": string;\n\t\"@graph\"?: JsonLdGraph[];\n\t\"@type\"?: string;\n}\n\nexport interface AlternateLinks {\n\tcanonical?: string;\n\tlanguages?: Record<string, string>;\n}\n\nexport interface RobotsGoogleBot {\n\tindex?: boolean;\n\tfollow?: boolean;\n\tnoimageindex?: boolean;\n\tmaxVideoPreview?: number;\n\tmaxImagePreview?: \"none\" | \"standard\" | \"large\";\n\tmaxSnippet?: number;\n}\n\nexport interface Robots {\n\tindex?: boolean;\n\tfollow?: boolean;\n\tnocache?: boolean;\n\tgoogleBot?: RobotsGoogleBot;\n}\n\nexport interface MetadataAuthor {\n\tname: string;\n\turl?: string;\n}\n\nexport interface MetadataIconItem {\n\turl: string;\n\tsizes?: string;\n\ttype?: string;\n}\n\nexport interface MetadataAppleIconItem {\n\turl: string;\n\tsizes?: string;\n}\n\nexport interface MetadataIcons {\n\ticon?: string | MetadataIconItem[];\n\tshortcut?: string;\n\tapple?: string | MetadataAppleIconItem[];\n}\n\nexport interface Metadata {\n\ttitle?: string;\n\ttitleTemplate?: string;\n\tdefaultTitle?: string;\n\tdescription?: string;\n\tkeywords?: string | string[];\n\tauthors?: MetadataAuthor[];\n\tcreator?: string;\n\tpublisher?: string;\n\tapplicationName?: string;\n\tthemeColor?: string;\n\tcolorScheme?: \"light\" | \"dark\" | \"light dark\" | \"dark light\";\n\tviewport?: string;\n\trobots?: string | Robots;\n\tcanonical?: string;\n\talternates?: AlternateLinks;\n\topenGraph?: OpenGraph;\n\ttwitter?: TwitterCard;\n\tjsonLd?: JsonLd | JsonLd[];\n\ticons?: MetadataIcons;\n\tmanifest?: string;\n\tother?: Record<string, string | string[]>;\n}\n\nexport function resolveTitle(metadata: Metadata): string {\n\tif (!metadata.title && metadata.defaultTitle) {\n\t\treturn metadata.defaultTitle;\n\t}\n\n\tif (!metadata.title) {\n\t\treturn \"\";\n\t}\n\n\tif (metadata.titleTemplate) {\n\t\treturn metadata.titleTemplate.replace(\"%s\", metadata.title);\n\t}\n\n\treturn metadata.title;\n}\n\nexport function resolveRobotsContent(robots: string | Robots): string {\n\tif (typeof robots === \"string\") {\n\t\treturn robots;\n\t}\n\n\tconst directives: string[] = [];\n\n\tif (robots.index === false) {\n\t\tdirectives.push(\"noindex\");\n\t} else {\n\t\tdirectives.push(\"index\");\n\t}\n\n\tif (robots.follow === false) {\n\t\tdirectives.push(\"nofollow\");\n\t} else {\n\t\tdirectives.push(\"follow\");\n\t}\n\n\tif (robots.nocache) {\n\t\tdirectives.push(\"nocache\");\n\t}\n\n\treturn directives.join(\", \");\n}\n\nexport function mergeMetadata(base: Metadata, override: Metadata): Metadata {\n\tconst mergedMetadata: Metadata = {\n\t\t...base,\n\t\t...override,\n\t};\n\n\tif (base.openGraph || override.openGraph) {\n\t\tmergedMetadata.openGraph = {\n\t\t\t...base.openGraph,\n\t\t\t...override.openGraph,\n\t\t};\n\t}\n\n\tif (base.twitter || override.twitter) {\n\t\tmergedMetadata.twitter = {\n\t\t\t...base.twitter,\n\t\t\t...override.twitter,\n\t\t};\n\t}\n\n\tif (base.alternates || override.alternates) {\n\t\tmergedMetadata.alternates = {\n\t\t\t...base.alternates,\n\t\t\t...override.alternates,\n\t\t};\n\t}\n\n\tif (base.icons || override.icons) {\n\t\tmergedMetadata.icons = {\n\t\t\t...base.icons,\n\t\t\t...override.icons,\n\t\t};\n\t}\n\n\tif (base.other || override.other) {\n\t\tmergedMetadata.other = {\n\t\t\t...base.other,\n\t\t\t...override.other,\n\t\t};\n\t}\n\n\treturn mergedMetadata;\n}\n\nexport type { GenerateMetadataFn } from \"../router/types\";\n",
|
|
39
|
+
"import { Fragment, type ReactElement } from \"react\";\nimport {\n\ttype JsonLd,\n\ttype Metadata,\n\ttype OpenGraphImage,\n\tresolveRobotsContent,\n\tresolveTitle,\n} from \"./metadata\";\n\nexport interface HeadProps {\n\tmetadata: Metadata;\n}\n\nfunction KeywordsContent(keywords: string | string[]): string {\n\treturn Array.isArray(keywords) ? keywords.join(\", \") : keywords;\n}\n\nfunction getAuthorKey(authorName: string): string {\n\treturn `author-${authorName}`;\n}\n\nfunction getIconKey(\n\tprefix: string,\n\ticonUrl: string,\n\ticonSizes?: string,\n): string {\n\tif (iconSizes && iconSizes.length > 0) {\n\t\treturn `${prefix}-${iconUrl}-${iconSizes}`;\n\t}\n\n\treturn `${prefix}-${iconUrl}`;\n}\n\nfunction getOpenGraphImageKey(image: OpenGraphImage): string {\n\tconst width = image.width ? String(image.width) : \"auto-width\";\n\tconst height = image.height ? String(image.height) : \"auto-height\";\n\n\treturn `og-image-${image.url}-${width}-${height}`;\n}\n\nfunction getJsonLdKey(schema: JsonLd): string {\n\treturn `jsonld-${JSON.stringify(schema)}`;\n}\n\nexport function RaktaHead({ metadata }: HeadProps): ReactElement {\n\tconst resolvedTitle = resolveTitle(metadata);\n\n\tconst robotsContent = metadata.robots\n\t\t? resolveRobotsContent(metadata.robots)\n\t\t: \"\";\n\n\tconst jsonLdArray: JsonLd[] = metadata.jsonLd\n\t\t? Array.isArray(metadata.jsonLd)\n\t\t\t? metadata.jsonLd\n\t\t\t: [metadata.jsonLd]\n\t\t: [];\n\n\tconst canonical = metadata.canonical ?? metadata.alternates?.canonical ?? \"\";\n\n\treturn (\n\t\t<>\n\t\t\t{/* Title meta */}\n\t\t\t{resolvedTitle && <title>{resolvedTitle}</title>}\n\n\t\t\t{/* Core meta */}\n\t\t\t{metadata.description && (\n\t\t\t\t<meta name=\"description\" content={metadata.description} />\n\t\t\t)}\n\t\t\t{metadata.keywords && (\n\t\t\t\t<meta name=\"keywords\" content={KeywordsContent(metadata.keywords)} />\n\t\t\t)}\n\t\t\t{metadata.applicationName && (\n\t\t\t\t<meta name=\"application-name\" content={metadata.applicationName} />\n\t\t\t)}\n\t\t\t{metadata.creator && <meta name=\"author\" content={metadata.creator} />}\n\t\t\t{metadata.publisher && (\n\t\t\t\t<meta name=\"publisher\" content={metadata.publisher} />\n\t\t\t)}\n\t\t\t{metadata.colorScheme && (\n\t\t\t\t<meta name=\"color-scheme\" content={metadata.colorScheme} />\n\t\t\t)}\n\t\t\t{robotsContent && <meta name=\"robots\" content={robotsContent} />}\n\t\t\t{metadata.viewport && (\n\t\t\t\t<meta name=\"viewport\" content={metadata.viewport} />\n\t\t\t)}\n\n\t\t\t{/* Authors meta */}\n\t\t\t{metadata.authors?.map((author) => (\n\t\t\t\t<meta\n\t\t\t\t\tkey={getAuthorKey(author.name)}\n\t\t\t\t\tname=\"author\"\n\t\t\t\t\tcontent={author.name}\n\t\t\t\t/>\n\t\t\t))}\n\n\t\t\t{/* Canonical meta */}\n\t\t\t{canonical && <link rel=\"canonical\" href={canonical} />}\n\n\t\t\t{/* Alternate languages meta */}\n\t\t\t{metadata.alternates?.languages &&\n\t\t\t\tObject.entries(metadata.alternates.languages).map(([lang, url]) => (\n\t\t\t\t\t<link rel=\"alternate\" key={lang} hrefLang={lang} href={url} />\n\t\t\t\t))}\n\n\t\t\t{/* Manifest */}\n\t\t\t{metadata.manifest && <link rel=\"manifest\" href={metadata.manifest} />}\n\n\t\t\t{/* Icons */}\n\t\t\t{metadata.icons?.icon &&\n\t\t\t\t(typeof metadata.icons.icon === \"string\" ? (\n\t\t\t\t\t<link rel=\"icon\" href={metadata.icons.icon} />\n\t\t\t\t) : (\n\t\t\t\t\tmetadata.icons.icon.map((icon) => (\n\t\t\t\t\t\t<link\n\t\t\t\t\t\t\tkey={getIconKey(\"icon\", icon.url, icon.sizes)}\n\t\t\t\t\t\t\trel=\"icon\"\n\t\t\t\t\t\t\thref={icon.url}\n\t\t\t\t\t\t\tsizes={icon.sizes}\n\t\t\t\t\t\t\ttype={icon.type}\n\t\t\t\t\t\t/>\n\t\t\t\t\t))\n\t\t\t\t))}\n\t\t\t{metadata.icons?.shortcut && (\n\t\t\t\t<link rel=\"shortcut icon\" href={metadata.icons.shortcut} />\n\t\t\t)}\n\t\t\t{metadata.icons?.apple &&\n\t\t\t\t(typeof metadata.icons.apple === \"string\" ? (\n\t\t\t\t\t<link rel=\"apple-touch-icon\" href={metadata.icons.apple} />\n\t\t\t\t) : (\n\t\t\t\t\tmetadata.icons.apple.map((icon) => (\n\t\t\t\t\t\t<link\n\t\t\t\t\t\t\tkey={getIconKey(\"apple\", icon.url, icon.sizes)}\n\t\t\t\t\t\t\trel=\"apple-touch-icon\"\n\t\t\t\t\t\t\thref={icon.url}\n\t\t\t\t\t\t\tsizes={icon.sizes}\n\t\t\t\t\t\t/>\n\t\t\t\t\t))\n\t\t\t\t))}\n\n\t\t\t{/* Open Graph */}\n\t\t\t{metadata.openGraph && (\n\t\t\t\t<>\n\t\t\t\t\t{(metadata.openGraph.title ?? resolvedTitle) && (\n\t\t\t\t\t\t<meta\n\t\t\t\t\t\t\tproperty=\"og:title\"\n\t\t\t\t\t\t\tcontent={metadata.openGraph.title ?? resolvedTitle}\n\t\t\t\t\t\t/>\n\t\t\t\t\t)}\n\t\t\t\t\t{(metadata.openGraph.description ?? metadata.description) && (\n\t\t\t\t\t\t<meta\n\t\t\t\t\t\t\tproperty=\"og:description\"\n\t\t\t\t\t\t\tcontent={\n\t\t\t\t\t\t\t\tmetadata.openGraph.description ?? metadata.description ?? \"\"\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t/>\n\t\t\t\t\t)}\n\t\t\t\t\t{metadata.openGraph.type && (\n\t\t\t\t\t\t<meta property=\"og:type\" content={metadata.openGraph.type} />\n\t\t\t\t\t)}\n\t\t\t\t\t{metadata.openGraph.url && (\n\t\t\t\t\t\t<meta property=\"og:url\" content={metadata.openGraph.url} />\n\t\t\t\t\t)}\n\t\t\t\t\t{metadata.openGraph.siteName && (\n\t\t\t\t\t\t<meta\n\t\t\t\t\t\t\tproperty=\"og:site_name\"\n\t\t\t\t\t\t\tcontent={metadata.openGraph.siteName}\n\t\t\t\t\t\t/>\n\t\t\t\t\t)}\n\t\t\t\t\t{metadata.openGraph.locale && (\n\t\t\t\t\t\t<meta property=\"og:locale\" content={metadata.openGraph.locale} />\n\t\t\t\t\t)}\n\t\t\t\t\t{metadata.openGraph.images?.map((image: OpenGraphImage) => (\n\t\t\t\t\t\t<Fragment key={getOpenGraphImageKey(image)}>\n\t\t\t\t\t\t\t<meta property=\"og:image\" content={image.url} />\n\t\t\t\t\t\t\t{image.width && (\n\t\t\t\t\t\t\t\t<meta property=\"og:image:width\" content={String(image.width)} />\n\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t{image.height && (\n\t\t\t\t\t\t\t\t<meta\n\t\t\t\t\t\t\t\t\tproperty=\"og:image:height\"\n\t\t\t\t\t\t\t\t\tcontent={String(image.height)}\n\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t{image.alt && (\n\t\t\t\t\t\t\t\t<meta property=\"og:image:alt\" content={image.alt} />\n\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t{image.type && (\n\t\t\t\t\t\t\t\t<meta property=\"og:image:type\" content={image.type} />\n\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t</Fragment>\n\t\t\t\t\t))}\n\t\t\t\t</>\n\t\t\t)}\n\n\t\t\t{/* Twitter Card */}\n\t\t\t{metadata.twitter && (\n\t\t\t\t<>\n\t\t\t\t\t<meta\n\t\t\t\t\t\tname=\"twitter:card\"\n\t\t\t\t\t\tcontent={metadata.twitter.card ?? \"summary\"}\n\t\t\t\t\t/>\n\t\t\t\t\t{metadata.twitter.site && (\n\t\t\t\t\t\t<meta name=\"twitter:site\" content={metadata.twitter.site} />\n\t\t\t\t\t)}\n\t\t\t\t\t{metadata.twitter.creator && (\n\t\t\t\t\t\t<meta name=\"twitter:creator\" content={metadata.twitter.creator} />\n\t\t\t\t\t)}\n\t\t\t\t\t{(metadata.twitter.title ?? resolvedTitle) && (\n\t\t\t\t\t\t<meta\n\t\t\t\t\t\t\tname=\"twitter:title\"\n\t\t\t\t\t\t\tcontent={metadata.twitter.title ?? resolvedTitle}\n\t\t\t\t\t\t/>\n\t\t\t\t\t)}\n\t\t\t\t\t{(metadata.twitter.description ?? metadata.description) && (\n\t\t\t\t\t\t<meta\n\t\t\t\t\t\t\tname=\"twitter:description\"\n\t\t\t\t\t\t\tcontent={\n\t\t\t\t\t\t\t\tmetadata.twitter.description ?? metadata.description ?? \"\"\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t/>\n\t\t\t\t\t)}\n\t\t\t\t\t{metadata.twitter.image && (\n\t\t\t\t\t\t<meta name=\"twitter:image\" content={metadata.twitter.image} />\n\t\t\t\t\t)}\n\t\t\t\t\t{metadata.twitter.imageAlt && (\n\t\t\t\t\t\t<meta\n\t\t\t\t\t\t\tname=\"twitter:image:alt\"\n\t\t\t\t\t\t\tcontent={metadata.twitter.imageAlt}\n\t\t\t\t\t\t/>\n\t\t\t\t\t)}\n\t\t\t\t</>\n\t\t\t)}\n\n\t\t\t{/* Custom meta */}\n\t\t\t{metadata.other &&\n\t\t\t\tObject.entries(metadata.other).map(([name, content]) => {\n\t\t\t\t\tconst contentValue = Array.isArray(content)\n\t\t\t\t\t\t? content.join(\", \")\n\t\t\t\t\t\t: content;\n\n\t\t\t\t\treturn <meta key={name} name={name} content={contentValue} />;\n\t\t\t\t})}\n\n\t\t\t{/* JSON-LD */}\n\t\t\t{jsonLdArray.map((schema) => (\n\t\t\t\t<script key={getJsonLdKey(schema)} type=\"application/ld+json\">\n\t\t\t\t\t{JSON.stringify(schema)}\n\t\t\t\t</script>\n\t\t\t))}\n\t\t</>\n\t);\n}\n\nexport default RaktaHead;\n",
|
|
40
|
+
"export interface RobotsRule {\n\tuserAgent: string | string[];\n\tallow?: string | string[];\n\tdisAllow?: string | string[];\n\tcrawlDelay?: number;\n}\n\nexport interface RobotsOptions {\n\trules: RobotsRule[];\n\tsitemap?: string | string[];\n\thost?: string;\n}\n\nexport function generateRobotsTxt(options: RobotsOptions): string {\n\tconst lines: string[] = [];\n\n\tfor (const rule of options.rules) {\n\t\tconst agents = Array.isArray(rule.userAgent)\n\t\t\t? rule.userAgent\n\t\t\t: [rule.userAgent];\n\n\t\tfor (const agent of agents) {\n\t\t\tlines.push(`User-agent: ${agent}`);\n\t\t}\n\n\t\tif (rule.allow) {\n\t\t\tconst allowPaths = Array.isArray(rule.allow) ? rule.allow : [rule.allow];\n\n\t\t\tfor (const allowPath of allowPaths) {\n\t\t\t\tlines.push(`Allow: ${allowPath}`);\n\t\t\t}\n\t\t}\n\n\t\tif (rule.disAllow) {\n\t\t\tconst disAllowPaths = Array.isArray(rule.disAllow)\n\t\t\t\t? rule.disAllow\n\t\t\t\t: [rule.disAllow];\n\n\t\t\tfor (const disAllowPath of disAllowPaths) {\n\t\t\t\tlines.push(`Disallow: ${disAllowPath}`);\n\t\t\t}\n\t\t}\n\n\t\tif (rule.crawlDelay !== undefined) {\n\t\t\tlines.push(`Crawl-delay: ${rule.crawlDelay}`);\n\t\t}\n\n\t\tlines.push(\"\");\n\t}\n\n\tif (options.sitemap) {\n\t\tconst sitemaps = Array.isArray(options.sitemap)\n\t\t\t? options.sitemap\n\t\t\t: [options.sitemap];\n\n\t\tfor (const sitemapUrl of sitemaps) {\n\t\t\tlines.push(`Sitemap: ${sitemapUrl}`);\n\t\t}\n\n\t\tlines.push(\"\");\n\t}\n\n\tif (options.host) {\n\t\tlines.push(`Host: ${options.host}`);\n\t}\n\n\treturn `${lines.join(\"\\n\").trimEnd()}\\n`;\n}\n\nexport function createRobotsHandler(options: RobotsOptions): () => Response {\n\treturn () => {\n\t\tconst robotsTxt = generateRobotsTxt(options);\n\n\t\treturn new Response(robotsTxt, {\n\t\t\tstatus: 200,\n\t\t\theaders: {\n\t\t\t\t\"Content-Type\": \"text/plain; charset=utf-8\",\n\t\t\t\t\"Cache-Control\": \"public, max-age=3600, s-maxage=86400\",\n\t\t\t},\n\t\t});\n\t};\n}\n",
|
|
41
|
+
"export type SitemapChangeFrequency =\n\t| \"always\"\n\t| \"hourly\"\n\t| \"daily\"\n\t| \"weekly\"\n\t| \"monthly\"\n\t| \"yearly\"\n\t| \"never\";\n\nexport interface SitemapImageEntry {\n\tloc: string;\n\tcaption?: string;\n\ttitle?: string;\n}\n\nexport interface SitemapEntry {\n\tloc: string;\n\tlastmod?: string;\n\tchangefreq?: SitemapChangeFrequency;\n\tpriority?: number;\n\timages?: SitemapImageEntry[];\n\talternates?: Record<string, string>;\n}\n\nexport interface SitemapOptions {\n\tbaseUrl: string;\n\tentries: SitemapEntry[];\n\txslUrl?: string;\n}\n\nexport interface SitemapIndexEntry {\n\tloc: string;\n\tlastmod?: string;\n}\n\nfunction encodeRaktaXmlValue(text: string): string {\n\treturn text\n\t\t.replace(/&/g, \"&\")\n\t\t.replace(/'/g, \"'\")\n\t\t.replace(/\"/g, \""\")\n\t\t.replace(/>/g, \">\")\n\t\t.replace(/</g, \"<\")\n\t\t.replace(/\\r/g, \"\")\n\t\t.replace(/\\n/g, \"\")\n\t\t.replace(/\\t/g, \" \")\n\t\t.trim();\n}\n\nfunction normalizeBaseUrl(baseUrl: string): string {\n\treturn baseUrl.endsWith(\"/\") ? baseUrl.slice(0, -1) : baseUrl;\n}\n\nfunction createAbsoluteUrl(baseUrl: string, loc: string): string {\n\tif (loc.startsWith(\"http://\") || loc.startsWith(\"https://\")) {\n\t\treturn loc;\n\t}\n\n\tif (loc.startsWith(\"/\")) {\n\t\treturn `${baseUrl}${loc}`;\n\t}\n\n\treturn `${baseUrl}/${loc}`;\n}\n\nfunction normalizePriority(priority: number): string {\n\tif (priority < 0) {\n\t\treturn \"0.0\";\n\t}\n\n\tif (priority > 1) {\n\t\treturn \"1.0\";\n\t}\n\n\treturn priority.toFixed(1);\n}\n\nexport function generateSitemapXml(options: SitemapOptions): string {\n\tconst { baseUrl, entries, xslUrl } = options;\n\tconst normalizedBase = normalizeBaseUrl(baseUrl);\n\tconst xmlParts: string[] = [];\n\n\txmlParts.push(`\n <?xml \n version=\"1.0\" \n encoding=\"UTF-8\"?\n >\n`);\n\n\tif (xslUrl) {\n\t\txmlParts.push(\n\t\t\t`<?xml-stylesheet \n type=\"text/xsl\"\n href=\"${encodeRaktaXmlValue(xslUrl)}\"?\n >`,\n\t\t);\n\t}\n\n\txmlParts.push(\n\t\t`<urlset ` +\n\t\t\t`xmlns=\"http://www.sitemaps.org/schemas/sitemap/0.9\" ` +\n\t\t\t`xmlns:image=\"http://www.google.com/schemas/sitemap-image/1.1\" ` +\n\t\t\t`xmlns:xhtml=\"http://www.w3.org/1999/xhtml\">`,\n\t);\n\n\tfor (const entry of entries) {\n\t\tconst fullLoc = createAbsoluteUrl(normalizedBase, entry.loc);\n\n\t\txmlParts.push(`<url>`);\n\t\txmlParts.push(`\n <loc>\n ${encodeRaktaXmlValue(fullLoc)}\n </loc>\n `);\n\n\t\tif (entry.lastmod) {\n\t\t\txmlParts.push(`\n <lastmod>\n ${encodeRaktaXmlValue(entry.lastmod)}\n </lastmod>\n `);\n\t\t}\n\n\t\tif (entry.changefreq) {\n\t\t\txmlParts.push(`\n <changefreq>\n ${entry.changefreq}\n </changefreq>\n `);\n\t\t}\n\n\t\tif (typeof entry.priority === \"number\") {\n\t\t\txmlParts.push(`\n <priority>\n ${normalizePriority(entry.priority)}\n </priority>\n `);\n\t\t}\n\n\t\tif (entry.alternates) {\n\t\t\tfor (const [lang, url] of Object.entries(entry.alternates)) {\n\t\t\t\tconst fullAlt = createAbsoluteUrl(normalizedBase, url);\n\n\t\t\t\txmlParts.push(\n\t\t\t\t\t`<xhtml:link \n rel=\"alternate\" \n hreflang=\"${encodeRaktaXmlValue(lang)}\" \n href=\"${encodeRaktaXmlValue(fullAlt)}\"\n />`,\n\t\t\t\t);\n\t\t\t}\n\t\t}\n\n\t\tif (entry.images) {\n\t\t\tfor (const image of entry.images) {\n\t\t\t\tconst imageLoc = createAbsoluteUrl(normalizedBase, image.loc);\n\n\t\t\t\txmlParts.push(`<image:image>`);\n\t\t\t\txmlParts.push(`\n <image:loc>\n ${encodeRaktaXmlValue(imageLoc)}\n </image:loc>\n `);\n\n\t\t\t\tif (image.caption) {\n\t\t\t\t\txmlParts.push(`\n <image:caption>\n ${encodeRaktaXmlValue(image.caption)}\n </image:caption>\n `);\n\t\t\t\t}\n\n\t\t\t\tif (image.title) {\n\t\t\t\t\txmlParts.push(`\n <image:title>\n ${encodeRaktaXmlValue(image.title)}\n </image:title>\n `);\n\t\t\t\t}\n\n\t\t\t\txmlParts.push(`</image:image>`);\n\t\t\t}\n\t\t}\n\n\t\txmlParts.push(`</url>`);\n\t}\n\n\txmlParts.push(`</urlset>`);\n\treturn xmlParts.join(\"\\n\");\n}\n\nexport function createSitemapHandler(options: SitemapOptions): () => Response {\n\treturn () => {\n\t\tconst xml = generateSitemapXml(options);\n\n\t\treturn new Response(xml, {\n\t\t\tstatus: 200,\n\t\t\theaders: {\n\t\t\t\t\"Content-Type\": \"application/xml; charset=utf-8\",\n\t\t\t\t\"Cache-Control\": \"public, max-age=3600, s-maxage=86400\",\n\t\t\t},\n\t\t});\n\t};\n}\n\nexport function generateSitemapIndexXml(\n\tbaseUrl: string,\n\tsitemaps: SitemapIndexEntry[],\n): string {\n\tconst normalizedBase = normalizeBaseUrl(baseUrl);\n\tconst xmlParts: string[] = [];\n\n\txmlParts.push(`\n <?xml \n version=\"1.0\" \n encoding=\"UTF-8\"?\n >\n `);\n\n\txmlParts.push(`\n <sitemapindex xmlns=\"http://www.sitemaps.org/schemas/sitemap/0.9\">\n `);\n\n\tfor (const entry of sitemaps) {\n\t\tconst fullLoc = createAbsoluteUrl(normalizedBase, entry.loc);\n\n\t\txmlParts.push(`<sitemap>`);\n\t\txmlParts.push(`\n <loc>\n ${encodeRaktaXmlValue(fullLoc)}\n </loc>\n `);\n\n\t\tif (entry.lastmod) {\n\t\t\txmlParts.push(`\n <lastmod>\n ${encodeRaktaXmlValue(entry.lastmod)}\n </lastmod>\n `);\n\t\t}\n\n\t\txmlParts.push(`</sitemap>`);\n\t}\n\n\txmlParts.push(`</sitemapindex>`);\n\treturn xmlParts.join(\"\\n\");\n}\n",
|
|
42
|
+
"import { useSyncExternalStore } from \"react\";\nimport type {\n\tListenerFn,\n\tSelectorFn,\n\tSetStateArg,\n\tStateCreator,\n\tStoreApi,\n\tUnsubscribeFn,\n} from \"./types\";\n\nfunction createStoreApi<TState>(\n\tcreator: StateCreator<TState>,\n): StoreApi<TState> {\n\tconst listeners = new Set<ListenerFn<TState>>();\n\tlet currentState: TState;\n\n\tconst getState = (): TState => currentState;\n\n\tconst emitChange = (nextState: TState, previousState: TState): void => {\n\t\tif (Object.is(previousState, nextState)) {\n\t\t\treturn;\n\t\t}\n\n\t\tfor (const listenerFn of listeners) {\n\t\t\tlistenerFn(nextState, previousState);\n\t\t}\n\t};\n\n\tconst setState = (arg: SetStateArg<TState>): void => {\n\t\tconst previousState = currentState;\n\t\tconst partialUpdate = typeof arg === \"function\" ? arg(currentState) : arg;\n\n\t\tcurrentState = {\n\t\t\t...currentState,\n\t\t\t...partialUpdate,\n\t\t};\n\n\t\temitChange(currentState, previousState);\n\t};\n\n\tconst subscribe = (listenerFn: ListenerFn<TState>): UnsubscribeFn => {\n\t\tlisteners.add(listenerFn);\n\n\t\treturn () => {\n\t\t\tlisteners.delete(listenerFn);\n\t\t};\n\t};\n\n\tcurrentState = creator(setState, getState);\n\tconst initialState = currentState;\n\n\tconst reset = (): void => {\n\t\tconst previousState = currentState;\n\t\tcurrentState = initialState;\n\n\t\temitChange(currentState, previousState);\n\t};\n\n\treturn {\n\t\tgetState,\n\t\tsetState,\n\t\tsubscribe,\n\t\treset,\n\t};\n}\n\nexport type UseStore<TState> = {\n\t(): TState;\n\t<TSelected>(selector: SelectorFn<TState, TSelected>): TSelected;\n} & StoreApi<TState>;\n\n/**\n * WaliSignal-powered Rakta Store — creates a reactive state store with React hooks.\n *\n * Usage:\n * const useCounterStore = createRaktaStore<CounterState>((set, get) => ({\n * count: 0,\n * increment: () => set({ count: get().count + 1 }),\n * }));\n *\n * const count = useCounterStore((state) => state.count);\n */\nexport function createRaktaStore<TState>(\n\tcreator: StateCreator<TState>,\n): UseStore<TState> {\n\tconst storeApi = createStoreApi(creator);\n\n\tfunction useStore(): TState;\n\tfunction useStore<TSelected>(\n\t\tselector: SelectorFn<TState, TSelected>,\n\t): TSelected;\n\tfunction useStore<TSelected>(\n\t\tselector?: SelectorFn<TState, TSelected>,\n\t): TState | TSelected {\n\t\tconst getSnapshot = (): TState | TSelected => {\n\t\t\tconst state = storeApi.getState();\n\n\t\t\tif (selector !== undefined) {\n\t\t\t\treturn selector(state);\n\t\t\t}\n\n\t\t\treturn state;\n\t\t};\n\n\t\treturn useSyncExternalStore(storeApi.subscribe, getSnapshot, getSnapshot);\n\t}\n\n\treturn Object.assign(useStore, storeApi);\n}\n",
|
|
43
|
+
"import { existsSync, readFileSync } from \"node:fs\";\nimport { join } from \"node:path\";\nimport { type RenderConfig, render, resolveRouteMode } from \"../render\";\nimport { generateManifest, matchRoute } from \"../router\";\nimport {\n\tbuildErrorResponse,\n\tbuildHtmlResponse,\n\tcreateRuntimeContext,\n} from \"./runtime\";\nimport type { TideAdapter, TideAdapterConfig } from \"./types\";\n\nconst STATIC_MIME_TYPES: Readonly<Record<string, string>> = {\n\t\".js\": \"application/javascript; charset=utf-8\",\n\t\".ts\": \"application/javascript; charset=utf-8\",\n\t\".css\": \"text/css; charset=utf-8\",\n\t\".json\": \"application/json; charset=utf-8\",\n\t\".png\": \"image/png\",\n\t\".jpg\": \"image/jpeg\",\n\t\".jpeg\": \"image/jpeg\",\n\t\".webp\": \"image/webp\",\n\t\".svg\": \"image/svg+xml\",\n\t\".ico\": \"image/x-icon\",\n\t\".woff\": \"font/woff\",\n\t\".woff2\": \"font/woff2\",\n};\n\ntype ApiRouteHandler = (request: Request) => Response | Promise<Response>;\n\ninterface ApiRouteExports {\n\treadonly GET?: ApiRouteHandler;\n\treadonly POST?: ApiRouteHandler;\n\treadonly PUT?: ApiRouteHandler;\n\treadonly PATCH?: ApiRouteHandler;\n\treadonly DELETE?: ApiRouteHandler;\n\treadonly HEAD?: ApiRouteHandler;\n\treadonly OPTIONS?: ApiRouteHandler;\n}\n\nfunction mimeForPath(filePath: string): string {\n\tconst extensionIndex = filePath.lastIndexOf(\".\");\n\n\tif (extensionIndex < 0) {\n\t\treturn \"application/octet-stream\";\n\t}\n\n\tconst extension = filePath.slice(extensionIndex).toLowerCase();\n\n\treturn STATIC_MIME_TYPES[extension] ?? \"application/octet-stream\";\n}\n\nfunction normalizeStaticPath(pathname: string): string {\n\tconst pathnameWithoutLeadingSlash = pathname.replace(/^\\/+/, \"\");\n\n\tif (pathnameWithoutLeadingSlash.length > 0) {\n\t\treturn pathnameWithoutLeadingSlash;\n\t}\n\n\treturn \"index.html\";\n}\n\nfunction isApiRouteExports(value: unknown): value is ApiRouteExports {\n\tif (typeof value !== \"object\" || value === null) {\n\t\treturn false;\n\t}\n\n\treturn true;\n}\n\nfunction getApiRouteHandler(\n\trouteExports: ApiRouteExports,\n\tmethod: string,\n): ApiRouteHandler | undefined {\n\tif (method === \"GET\") {\n\t\treturn routeExports.GET;\n\t}\n\n\tif (method === \"POST\") {\n\t\treturn routeExports.POST;\n\t}\n\n\tif (method === \"PUT\") {\n\t\treturn routeExports.PUT;\n\t}\n\n\tif (method === \"PATCH\") {\n\t\treturn routeExports.PATCH;\n\t}\n\n\tif (method === \"DELETE\") {\n\t\treturn routeExports.DELETE;\n\t}\n\n\tif (method === \"HEAD\") {\n\t\treturn routeExports.HEAD;\n\t}\n\n\tif (method === \"OPTIONS\") {\n\t\treturn routeExports.OPTIONS;\n\t}\n\n\treturn undefined;\n}\n\n/**\n * Creates the Bun Tide adapter.\n * Handles static files, API routes, and page rendering.\n */\nexport function createBunAdapter(\n\tadapterConfig: TideAdapterConfig,\n\trenderConfig: RenderConfig,\n): TideAdapter {\n\tconst manifest = generateManifest(adapterConfig.appDir);\n\tconst searchDirectories = [adapterConfig.publicDir, adapterConfig.outDir];\n\n\tlet serverInstance: ReturnType<typeof Bun.serve> | undefined;\n\n\tasync function handle(request: Request): Promise<Response> {\n\t\tconst url = new URL(request.url);\n\t\tconst { pathname } = url;\n\t\tconst staticPathname = normalizeStaticPath(pathname);\n\n\t\tfor (const searchDirectory of searchDirectories) {\n\t\t\tconst filePath = join(searchDirectory, staticPathname);\n\n\t\t\tif (existsSync(filePath) && !filePath.endsWith(\"/\")) {\n\t\t\t\treturn new Response(readFileSync(filePath), {\n\t\t\t\t\theaders: {\n\t\t\t\t\t\t\"Content-Type\": mimeForPath(filePath),\n\t\t\t\t\t\t\"Cache-Control\": \"public, max-age=31536000, immutable\",\n\t\t\t\t\t},\n\t\t\t\t});\n\t\t\t}\n\t\t}\n\n\t\tconst apiRoutes = manifest.routes.filter((route) => route.kind === \"api\");\n\t\tconst apiMatch = matchRoute(pathname, apiRoutes);\n\n\t\tif (apiMatch) {\n\t\t\tconst modulePath = join(adapterConfig.appDir, apiMatch.entry.filePath);\n\n\t\t\tconst routeModule: unknown = await import(modulePath);\n\n\t\t\tif (!isApiRouteExports(routeModule)) {\n\t\t\t\treturn new Response(\"Invalid API route module\", {\n\t\t\t\t\tstatus: 500,\n\t\t\t\t});\n\t\t\t}\n\n\t\t\tconst handler = getApiRouteHandler(\n\t\t\t\trouteModule,\n\t\t\t\trequest.method.toUpperCase(),\n\t\t\t);\n\n\t\t\tif (!handler) {\n\t\t\t\treturn new Response(\"Method not allowed\", {\n\t\t\t\t\tstatus: 405,\n\t\t\t\t});\n\t\t\t}\n\n\t\t\treturn await handler(request);\n\t\t}\n\n\t\tconst resolvedRouteMode = resolveRouteMode(pathname, renderConfig);\n\n\t\tconst runtimeContext = createRuntimeContext(\n\t\t\trequest,\n\t\t\turl,\n\t\t\t{},\n\t\t\tresolvedRouteMode.mode,\n\t\t);\n\n\t\tconst renderResult = await render(\n\t\t\t{\n\t\t\t\troutePath: runtimeContext.pathname,\n\t\t\t\tmode: runtimeContext.resolvedMode,\n\t\t\t\tparams: runtimeContext.params,\n\t\t\t\tsearchParams: runtimeContext.searchParams,\n\t\t\t\trequestHeaders: runtimeContext.requestHeaders,\n\t\t\t\ttimestampMs: runtimeContext.timestampMs,\n\t\t\t},\n\t\t\t{\n\t\t\t\tappName: adapterConfig.appName,\n\t\t\t\tscriptPath: \"/app.js\",\n\t\t\t\tcssPath: \"/globals.css\",\n\t\t\t\tlang: \"en\",\n\t\t\t},\n\t\t);\n\n\t\tif (renderResult.kind === \"failure\") {\n\t\t\treturn buildErrorResponse(renderResult.reason, renderResult.httpStatus);\n\t\t}\n\n\t\treturn buildHtmlResponse(renderResult.html, renderResult.httpStatus);\n\t}\n\n\treturn {\n\t\tkind: \"bun\",\n\t\thandle,\n\t\tstart: async (): Promise<void> => {\n\t\t\tserverInstance = Bun.serve({\n\t\t\t\tport: adapterConfig.port,\n\t\t\t\thostname: adapterConfig.host,\n\t\t\t\tfetch: handle,\n\t\t\t});\n\n\t\t\tconsole.log(\n\t\t\t\t`[Rakta.js Tide] Running at http://${adapterConfig.host}:${serverInstance.port}`,\n\t\t\t);\n\t\t},\n\t\tstop: (): void => {\n\t\t\tif (!serverInstance) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tserverInstance.stop();\n\t\t},\n\t};\n}\n",
|
|
44
|
+
"import type { RenderMode } from \"rakta/render\";\nimport type { TideRuntimeContext } from \"./types\";\n\nexport function createRuntimeContext(\n\trequest: Request,\n\turl: URL,\n\tparams: Readonly<Record<string, string>>,\n\tresolvedMode: RenderMode,\n): TideRuntimeContext {\n\tconst searchParams: Record<string, string> = {};\n\turl.searchParams.forEach((value, key) => {\n\t\tsearchParams[key] = value;\n\t});\n\n\tconst requestHeaders: Record<string, string> = {};\n\trequest.headers.forEach((value, key) => {\n\t\trequestHeaders[key] = value;\n\t});\n\n\treturn {\n\t\turl,\n\t\tparams,\n\t\trequest,\n\t\tsearchParams,\n\t\tresolvedMode,\n\t\trequestHeaders,\n\t\tpathname: url.pathname,\n\t\ttimestampMs: Date.now(),\n\t\tmethod: request.method.toUpperCase(),\n\t};\n}\n\nexport function buildTextResponse(\n\tbody: string,\n\tstatus: number,\n\theaders: Record<string, string>,\n): Response {\n\treturn new Response(body, { status, headers });\n}\n\nexport function buildHtmlResponse(\n\thtml: string,\n\tstatus: number = 200,\n): Response {\n\treturn buildTextResponse(html, status, {\n\t\t\"Content-Type\": \"text/html; charset=utf-8\",\n\t});\n}\n\nexport function buildJsonResponse(\n\tresponseData: Record<string, string | number | boolean | object>,\n\tstatus: number = 200,\n): Response {\n\treturn buildTextResponse(JSON.stringify(responseData), status, {\n\t\t\"Content-Type\": \"application/json; charset=utf-8\",\n\t});\n}\n\nexport function buildErrorResponse(\n\terrorMessage: string,\n\tstatus: number = 500,\n): Response {\n\treturn buildJsonResponse({ error: errorMessage }, status);\n}\n",
|
|
45
|
+
"export const RAKTA_NAME = \"Rakta.js\";\nexport const RAKTA_VERSION = \"0.1.0\";\nexport const RAKTA_TAGLINE =\n\t\"Small in size. Fierce in speed. Alive in every route.\";\n\nexport type {\n\tAutoImportGeneratorOptions,\n\tAutoImportKind,\n\tAutoImportManifest,\n\tDiscoveredExport,\n\tScanForExportsOptions,\n} from \"./auto-import/index\";\n\n// Auto Import — TrusmiThread\nexport {\n\tgenerateAutoImports,\n\tprintAutoImportSummary,\n\tscanForExports,\n} from \"./auto-import/index\";\nexport type {\n\tClickProps,\n\tPictureProps,\n\tPictureProps as PhotoProps,\n} from \"./components/index\";\n\n// Components\nexport {\n\tClick,\n\tPicture,\n\tPicture as Photo,\n} from \"./components/index\";\nexport type {\n\tAutoImportConfig,\n\tBuildConfig,\n\tCorsConfig,\n\tCssConfig,\n\tRaktaConfig,\n\tRpcConfig,\n\tSeoConfig,\n\tServerConfig,\n} from \"./config/index\";\n\n// Config\nexport {\n\tdefaultConfig,\n\tdefineConfig,\n\tdefineRaktaConfig,\n\tloadConfig,\n\tmergeConfig,\n} from \"./config/index\";\nexport type {\n\tArtifactKind,\n\tForgeBuildArtifact,\n\tForgeBuildOptions,\n\tForgeBuildResult,\n\tForgeDevServerHandle,\n\tForgeDevServerOptions,\n\tForgeInspectReport,\n\tForgeRouteModeEntry,\n\tInspectOptions,\n} from \"./forge/index\";\n\n// Forge — CherbonsEngine\nexport {\n\tbuildProject,\n\tinspectBuild,\n\tprintInspectReport,\n\tstartDevServer,\n} from \"./forge/index\";\nexport type {\n\tHttpClientConfig,\n\tHttpJsonArray,\n\tHttpJsonObject,\n\tHttpJsonPrimitive,\n\tHttpJsonValue,\n\tHttpMethod,\n\tHttpQueryParams,\n\tHttpQueryValue,\n\tHttpRequestBody,\n\tHttpRequestConfig,\n\tRequestInterceptorFn,\n\tResponseInterceptorFn,\n} from \"./http/index\";\n\n// HTTP — PanturaFetch\nexport {\n\tcreateRaktaHttp,\n\tHttpNetworkError,\n\tHttpResponseError,\n\tHttpTimeoutError,\n\tRaktaHttpClient,\n} from \"./http/index\";\nexport type {\n\tCacheStrategyOptions,\n\tManifestDisplayMode,\n\tManifestIcon,\n\tManifestOptions,\n\tServiceWorkerOptions,\n} from \"./pwa/index\";\n\n// PWA — ShrimpHarbor\nexport {\n\tbuildCacheName,\n\tcreateManifestHandler,\n\tgenerateManifest as generatePwaManifest,\n\tgenerateManifestJson,\n\tgenerateServiceWorkerSource,\n\tresolvePrecacheList,\n} from \"./pwa/index\";\nexport type {\n\tHybridRouteEntry,\n\tRenderConfig,\n\tRenderContext,\n\tRendererOptions,\n\tRenderFailure,\n\tRenderMode,\n\tRenderModeDescriptor,\n\tRenderResult,\n\tRenderSource,\n\tRenderSuccess,\n\tResolvedRouteMode,\n\tRouteRenderMap,\n\tStaticEntry,\n} from \"./render/index\";\n\n// Render\nexport {\n\tgetModeDescriptor,\n\tisBuildTimeMode,\n\tisRoadmapMode,\n\tRENDER_MODE_DESCRIPTORS,\n\trender,\n\trenderNotFound,\n\trenderServerError,\n\trequiresServer,\n\tresolveRouteMode,\n} from \"./render/index\";\nexport type {\n\tApiMethod,\n\tApiRouteHandler,\n\tApiRouteModule,\n\tGenerateMetadataFn,\n\tLayoutProps,\n\tMatchedRoute,\n\tPageProps,\n\tRouteContext,\n\tRouteKind,\n\tRouteManifest,\n\tRouteManifestEntry,\n\tRouteSegment,\n} from \"./router/index\";\n\n// Router\nexport {\n\tfindLayoutsForPathname,\n\tfindSpecialRoute,\n\tgenerateManifest,\n\tmatchRoute,\n\tprintManifest,\n\treadManifest,\n\tscanRoutes,\n\twriteManifest,\n} from \"./router/index\";\nexport type {\n\tInferInput,\n\tInferOutput,\n\tProcedureDefinition,\n\tProcedureKind,\n\tRaktaClientConfig,\n\tRouterClient,\n\tRouterDefinition,\n\tRpcEnvelope,\n\tRpcErrorEnvelope,\n\tRpcPayload,\n\tRpcSuccessEnvelope,\n} from \"./rpc/index\";\n\n// RPC\nexport {\n\tcreateRaktaClient,\n\tcreateRaktaRouter,\n\tcreateRpcHandler,\n\tProcedureBuilder,\n\tpublicProcedure,\n\tRaktaRpcError,\n} from \"./rpc/index\";\nexport type {\n\tInfer,\n\tInferShape,\n\tParseFailure,\n\tParseResult,\n\tParseSuccess,\n\tShapeRecord,\n\tValidationError,\n} from \"./schema/index\";\n\n// Schema\nexport {\n\tArrayType,\n\tarray,\n\tBooleanType,\n\tboolean,\n\tNumberType,\n\tnumber,\n\tObjectType,\n\tOptionalType,\n\tobject,\n\tpreFixErrors,\n\tRaktaSchemaError,\n\tRaktaType,\n\tStringType,\n\tstring,\n} from \"./schema/index\";\nexport type {\n\tAlternateLinks,\n\tHeadProps,\n\tJsonLd,\n\tJsonLdGraph,\n\tMetadata,\n\tOpenGraph,\n\tOpenGraphImage,\n\tRobots,\n\tRobotsOptions,\n\tRobotsRule,\n\tSitemapEntry,\n\tSitemapIndexEntry,\n\tSitemapOptions,\n\tTwitterCard,\n} from \"./seo/index\";\n\n// SEO\nexport {\n\tcreateRobotsHandler,\n\tcreateSitemapHandler,\n\tgenerateRobotsTxt,\n\tgenerateSitemapIndexXml,\n\tgenerateSitemapXml,\n\tmergeMetadata,\n\tRaktaHead,\n\tresolveRobotsContent,\n\tresolveTitle,\n} from \"./seo/index\";\nexport type {\n\tGetStateFn,\n\tListenerFn,\n\tSelectorFn,\n\tSetStateArg,\n\tSetStateFn,\n\tStateCreator,\n\tStoreApi,\n\tUnsubscribeFn,\n} from \"./store/index\";\n\n// Store\nexport { createRaktaStore } from \"./store/index\";\nexport type {\n\tTideAdapter,\n\tTideAdapterConfig,\n\tTideAdapterKind,\n\tTideRender,\n\tTideRenderStrategyResult,\n\tTideResponseBlueprint,\n\tTideRuntimeContext,\n} from \"./tide/index\";\n\n// Tide — NorthCoastFlow\nexport {\n\tbuildErrorResponse,\n\tbuildHtmlResponse,\n\tbuildJsonResponse,\n\tbuildTextResponse,\n\tcreateBunAdapter,\n\tcreateRuntimeContext,\n} from \"./tide/index\";\n"
|
|
46
|
+
],
|
|
47
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAYG,QAAS,GAAG;AAAA,IACX,SAAS,wBAAwB,CAAC,YAAY,MAAM;AAAA,MAClD,OAAO,eAAe,UAAU,WAAW,YAAY;AAAA,QACrD,KAAK,QAAS,GAAG;AAAA,UACf,QAAQ,KACN,+DACA,KAAK,IACL,KAAK,EACP;AAAA;AAAA,MAEJ,CAAC;AA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