@askrjs/askr 0.0.4 → 0.0.6
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/dist/{index.d.cts → component-BBGWJdqJ.d.ts} +42 -33
- package/dist/foundations/index.d.ts +32 -0
- package/dist/{chunk-WTFWRSHB.js → foundations/index.js} +76 -28
- package/dist/foundations/index.js.map +1 -0
- package/dist/fx/index.js +295 -77
- package/dist/fx/index.js.map +1 -1
- package/dist/index.d.ts +4 -134
- package/dist/index.js +3709 -42
- package/dist/index.js.map +1 -1
- package/dist/{jsx/jsx-dev-runtime.d.ts → jsx-dev-runtime.d.ts} +3 -3
- package/dist/jsx-dev-runtime.js +17 -0
- package/dist/jsx-dev-runtime.js.map +1 -0
- package/dist/jsx-runtime.d.ts +14 -0
- package/dist/{chunk-SALJX5PZ.js → jsx-runtime.js} +6 -9
- package/dist/jsx-runtime.js.map +1 -0
- package/dist/layout-D5MqtW_q.d.ts +14 -0
- package/dist/resources/index.d.ts +3 -0
- package/dist/resources/index.js +753 -239
- package/dist/resources/index.js.map +1 -1
- package/dist/router/index.d.ts +2 -14
- package/dist/router/index.js +3115 -19
- package/dist/router/index.js.map +1 -1
- package/dist/ssr/index.js +3363 -103
- package/dist/ssr/index.js.map +1 -1
- package/dist/{types-CZHOAiC1.d.ts → types-uOPfcrdz.d.ts} +3 -1
- package/dist/vite/index.d.ts +17 -0
- package/dist/vite/index.js +2306 -0
- package/dist/vite/index.js.map +1 -0
- package/package.json +21 -23
- package/dist/chunk-64C7W2AE.js +0 -43
- package/dist/chunk-64C7W2AE.js.map +0 -1
- package/dist/chunk-6FLMH4EL.js +0 -124
- package/dist/chunk-6FLMH4EL.js.map +0 -1
- package/dist/chunk-FJUXFA72.js +0 -16
- package/dist/chunk-FJUXFA72.js.map +0 -1
- package/dist/chunk-SALJX5PZ.js.map +0 -1
- package/dist/chunk-VRAEBIJ3.js +0 -82
- package/dist/chunk-VRAEBIJ3.js.map +0 -1
- package/dist/chunk-WTFWRSHB.js.map +0 -1
- package/dist/chunk-XHKZGJE3.js +0 -2907
- package/dist/chunk-XHKZGJE3.js.map +0 -1
- package/dist/chunk-Z5ZSTLYF.js +0 -420
- package/dist/chunk-Z5ZSTLYF.js.map +0 -1
- package/dist/fx/index.cjs +0 -1193
- package/dist/fx/index.cjs.map +0 -1
- package/dist/fx/index.d.cts +0 -186
- package/dist/index.cjs +0 -4035
- package/dist/index.cjs.map +0 -1
- package/dist/jsx/jsx-dev-runtime.cjs +0 -46
- package/dist/jsx/jsx-dev-runtime.cjs.map +0 -1
- package/dist/jsx/jsx-dev-runtime.d.cts +0 -12
- package/dist/jsx/jsx-dev-runtime.js +0 -19
- package/dist/jsx/jsx-dev-runtime.js.map +0 -1
- package/dist/jsx/jsx-runtime.cjs +0 -54
- package/dist/jsx/jsx-runtime.cjs.map +0 -1
- package/dist/jsx/jsx-runtime.d.cts +0 -21
- package/dist/jsx/jsx-runtime.d.ts +0 -21
- package/dist/jsx/jsx-runtime.js +0 -16
- package/dist/jsx/jsx-runtime.js.map +0 -1
- package/dist/jsx-AzPM8gMS.d.cts +0 -35
- package/dist/navigate-LUVYHYZZ.js +0 -17
- package/dist/navigate-LUVYHYZZ.js.map +0 -1
- package/dist/resources/index.cjs +0 -1200
- package/dist/resources/index.cjs.map +0 -1
- package/dist/resources/index.d.cts +0 -21
- package/dist/route-BCND6MPK.js +0 -32
- package/dist/route-BCND6MPK.js.map +0 -1
- package/dist/router/index.cjs +0 -3247
- package/dist/router/index.cjs.map +0 -1
- package/dist/router/index.d.cts +0 -64
- package/dist/router-DaGtH1Sq.d.cts +0 -36
- package/dist/ssr/index.cjs +0 -4059
- package/dist/ssr/index.cjs.map +0 -1
- package/dist/ssr/index.d.cts +0 -123
- package/dist/types-CZ5sWur5.d.cts +0 -23
- package/src/jsx/index.ts +0 -4
- package/src/jsx/jsx-dev-runtime.ts +0 -23
- package/src/jsx/jsx-runtime.ts +0 -48
- package/src/jsx/types.ts +0 -33
- package/src/jsx/utils.ts +0 -19
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import '
|
|
2
|
-
import { J as JSXElement } from '
|
|
3
|
-
export { F as Fragment } from '
|
|
1
|
+
import './types-uOPfcrdz.js';
|
|
2
|
+
import { J as JSXElement } from './jsx-AzPM8gMS.js';
|
|
3
|
+
export { F as Fragment } from './jsx-AzPM8gMS.js';
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
6
|
* JSX dev runtime factory
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
// src/common/jsx.ts
|
|
2
|
+
var ELEMENT_TYPE = /* @__PURE__ */ Symbol.for("askr.element");
|
|
3
|
+
var Fragment = /* @__PURE__ */ Symbol.for("askr.fragment");
|
|
4
|
+
|
|
5
|
+
// src/jsx/jsx-dev-runtime.ts
|
|
6
|
+
function jsxDEV(type, props, key) {
|
|
7
|
+
return {
|
|
8
|
+
$$typeof: ELEMENT_TYPE,
|
|
9
|
+
type,
|
|
10
|
+
props: props ?? {},
|
|
11
|
+
key: key ?? null
|
|
12
|
+
};
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
export { Fragment, jsxDEV };
|
|
16
|
+
//# sourceMappingURL=jsx-dev-runtime.js.map
|
|
17
|
+
//# sourceMappingURL=jsx-dev-runtime.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/common/jsx.ts","../src/jsx/jsx-dev-runtime.ts"],"names":[],"mappings":";AAMO,IAAM,YAAA,mBAAe,MAAA,CAAO,GAAA,CAAI,cAAc,CAAA;AAC9C,IAAM,QAAA,mBAAW,MAAA,CAAO,GAAA,CAAI,eAAe;;;ACD3C,SAAS,MAAA,CACd,IAAA,EACA,KAAA,EACA,GAAA,EACY;AACZ,EAAA,OAAO;AAAA,IACL,QAAA,EAAU,YAAA;AAAA,IACV,IAAA;AAAA,IACA,KAAA,EAAO,SAAS,EAAC;AAAA,IACjB,KAAK,GAAA,IAAO;AAAA,GACd;AACF","file":"jsx-dev-runtime.js","sourcesContent":["/**\n * Common call contracts: JSX element shape\n */\n\nimport type { Props } from './props';\n\nexport const ELEMENT_TYPE = Symbol.for('askr.element');\nexport const Fragment = Symbol.for('askr.fragment');\n\nexport interface JSXElement {\n /** Internal element marker (optional for plain vnode objects) */\n $$typeof?: symbol;\n\n /** Element type: string, component, Fragment, etc */\n type: unknown;\n\n /** Props bag */\n props: Props;\n\n /** Optional key (normalized by runtime) */\n key?: string | number | null;\n}\n","/**\n * JSX dev runtime factory\n * Same element shape as production runtime, with room for dev warnings.\n */\nimport { ELEMENT_TYPE, Fragment, JSXElement } from './types';\n\nexport function jsxDEV(\n type: unknown,\n props: Record<string, unknown> | null,\n key?: string | number\n): JSXElement {\n return {\n $$typeof: ELEMENT_TYPE,\n type,\n props: props ?? {},\n key: key ?? null,\n };\n}\n\n// Re-export Fragment for JSX\nexport { Fragment };\n"]}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import './types-uOPfcrdz.js';
|
|
2
|
+
import { J as JSXElement } from './jsx-AzPM8gMS.js';
|
|
3
|
+
export { F as Fragment } from './jsx-AzPM8gMS.js';
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* JSX runtime factory
|
|
7
|
+
* Same element shape as production runtime.
|
|
8
|
+
*/
|
|
9
|
+
|
|
10
|
+
declare function jsxDEV(type: unknown, props: Record<string, unknown> | null, key?: string | number): JSXElement;
|
|
11
|
+
declare function jsx(type: unknown, props: Record<string, unknown> | null, key?: string | number): JSXElement;
|
|
12
|
+
declare function jsxs(type: unknown, props: Record<string, unknown> | null, key?: string | number): JSXElement;
|
|
13
|
+
|
|
14
|
+
export { jsx, jsxDEV, jsxs };
|
|
@@ -1,6 +1,8 @@
|
|
|
1
|
-
// src/
|
|
1
|
+
// src/common/jsx.ts
|
|
2
2
|
var ELEMENT_TYPE = /* @__PURE__ */ Symbol.for("askr.element");
|
|
3
3
|
var Fragment = /* @__PURE__ */ Symbol.for("askr.fragment");
|
|
4
|
+
|
|
5
|
+
// src/jsx/jsx-runtime.ts
|
|
4
6
|
function jsxDEV(type, props, key) {
|
|
5
7
|
return {
|
|
6
8
|
$$typeof: ELEMENT_TYPE,
|
|
@@ -16,11 +18,6 @@ function jsxs(type, props, key) {
|
|
|
16
18
|
return jsxDEV(type, props, key);
|
|
17
19
|
}
|
|
18
20
|
|
|
19
|
-
export {
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
jsxDEV,
|
|
23
|
-
jsx,
|
|
24
|
-
jsxs
|
|
25
|
-
};
|
|
26
|
-
//# sourceMappingURL=chunk-SALJX5PZ.js.map
|
|
21
|
+
export { Fragment, jsx, jsxDEV, jsxs };
|
|
22
|
+
//# sourceMappingURL=jsx-runtime.js.map
|
|
23
|
+
//# sourceMappingURL=jsx-runtime.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/common/jsx.ts","../src/jsx/jsx-runtime.ts"],"names":[],"mappings":";AAMO,IAAM,YAAA,mBAAe,MAAA,CAAO,GAAA,CAAI,cAAc,CAAA;AAC9C,IAAM,QAAA,mBAAW,MAAA,CAAO,GAAA,CAAI,eAAe;;;ACA3C,SAAS,MAAA,CACd,IAAA,EACA,KAAA,EACA,GAAA,EACY;AACZ,EAAA,OAAO;AAAA,IACL,QAAA,EAAU,YAAA;AAAA,IACV,IAAA;AAAA,IACA,KAAA,EAAO,SAAS,EAAC;AAAA,IACjB,KAAK,GAAA,IAAO;AAAA,GACd;AACF;AAGO,SAAS,GAAA,CACd,IAAA,EACA,KAAA,EACA,GAAA,EACA;AACA,EAAA,OAAO,MAAA,CAAO,IAAA,EAAM,KAAA,EAAO,GAAG,CAAA;AAChC;AAEO,SAAS,IAAA,CACd,IAAA,EACA,KAAA,EACA,GAAA,EACA;AACA,EAAA,OAAO,MAAA,CAAO,IAAA,EAAM,KAAA,EAAO,GAAG,CAAA;AAChC","file":"jsx-runtime.js","sourcesContent":["/**\n * Common call contracts: JSX element shape\n */\n\nimport type { Props } from './props';\n\nexport const ELEMENT_TYPE = Symbol.for('askr.element');\nexport const Fragment = Symbol.for('askr.fragment');\n\nexport interface JSXElement {\n /** Internal element marker (optional for plain vnode objects) */\n $$typeof?: symbol;\n\n /** Element type: string, component, Fragment, etc */\n type: unknown;\n\n /** Props bag */\n props: Props;\n\n /** Optional key (normalized by runtime) */\n key?: string | number | null;\n}\n","/**\n * JSX runtime factory\n * Same element shape as production runtime.\n */\n\nimport { ELEMENT_TYPE, Fragment, type JSXElement } from './types';\n\nexport function jsxDEV(\n type: unknown,\n props: Record<string, unknown> | null,\n key?: string | number\n): JSXElement {\n return {\n $$typeof: ELEMENT_TYPE,\n type,\n props: props ?? {},\n key: key ?? null,\n };\n}\n\n// Production-style helpers: alias to the DEV factory for now\nexport function jsx(\n type: unknown,\n props: Record<string, unknown> | null,\n key?: string | number\n) {\n return jsxDEV(type, props, key);\n}\n\nexport function jsxs(\n type: unknown,\n props: Record<string, unknown> | null,\n key?: string | number\n) {\n return jsxDEV(type, props, key);\n}\n\n// Re-export Fragment for JSX.\nexport { Fragment };\n"]}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Layout helper.
|
|
3
|
+
*
|
|
4
|
+
* A layout is just a normal component that wraps children.
|
|
5
|
+
* Persistence and reuse are handled by the runtime via component identity.
|
|
6
|
+
*
|
|
7
|
+
* This helper exists purely for readability and convention.
|
|
8
|
+
*/
|
|
9
|
+
type LayoutComponent<P = object> = (props: P & {
|
|
10
|
+
children?: unknown;
|
|
11
|
+
}) => unknown;
|
|
12
|
+
declare function layout<P = object>(Layout: LayoutComponent<P>): (children?: unknown, props?: P) => unknown;
|
|
13
|
+
|
|
14
|
+
export { type LayoutComponent as L, layout as l };
|