vorma 0.0.0-pre.0 → 0.82.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/LICENSE +28 -0
- package/README.md +48 -0
- package/internal/framework/_typescript/client/index.ts +64 -0
- package/internal/framework/_typescript/client/src/asset_manager.ts +67 -0
- package/internal/framework/_typescript/client/src/client.ts +1201 -0
- package/internal/framework/_typescript/client/src/client_loaders.ts +249 -0
- package/internal/framework/_typescript/client/src/component_loader.ts +105 -0
- package/internal/framework/_typescript/client/src/error_boundary.ts +7 -0
- package/internal/framework/_typescript/client/src/events.ts +54 -0
- package/internal/framework/_typescript/client/src/global_loading_indicator/global_loading_indicator.ts +125 -0
- package/internal/framework/_typescript/client/src/hard_reload.ts +1 -0
- package/internal/framework/_typescript/client/src/head_elements/head_elements.ts +193 -0
- package/internal/framework/_typescript/client/src/history/history.ts +118 -0
- package/internal/framework/_typescript/client/src/history/npm_history_types.ts +83 -0
- package/internal/framework/_typescript/client/src/hmr/hmr.ts +71 -0
- package/internal/framework/_typescript/client/src/init_client.ts +134 -0
- package/internal/framework/_typescript/client/src/links.ts +218 -0
- package/internal/framework/_typescript/client/src/redirects/redirects.ts +203 -0
- package/internal/framework/_typescript/client/src/rendering.ts +135 -0
- package/internal/framework/_typescript/client/src/resolve_public_href.ts +15 -0
- package/internal/framework/_typescript/client/src/scroll_state_manager.ts +100 -0
- package/internal/framework/_typescript/client/src/static_route_defs/route_def_helpers.ts +22 -0
- package/internal/framework/_typescript/client/src/ui_lib_impl_helpers/link_components.ts +131 -0
- package/internal/framework/_typescript/client/src/ui_lib_impl_helpers/route_components.ts +56 -0
- package/internal/framework/_typescript/client/src/ui_lib_impl_helpers/typed_navigate.ts +58 -0
- package/internal/framework/_typescript/client/src/utils/errors.ts +10 -0
- package/internal/framework/_typescript/client/src/utils/logging.ts +7 -0
- package/internal/framework/_typescript/client/src/vorma_app_helpers/vorma_app_helpers.ts +290 -0
- package/internal/framework/_typescript/client/src/vorma_ctx/vorma_ctx.ts +128 -0
- package/internal/framework/_typescript/client/src/window_focus_revalidation/window_focus_revalidation.ts +32 -0
- package/internal/framework/_typescript/client/tsconfig.json +3 -0
- package/internal/framework/_typescript/create/main.ts +378 -0
- package/internal/framework/_typescript/create/package.json +33 -0
- package/internal/framework/_typescript/create/pnpm-lock.yaml +70 -0
- package/internal/framework/_typescript/create/tsconfig.json +3 -0
- package/internal/framework/_typescript/preact/index.tsx +10 -0
- package/internal/framework/_typescript/preact/src/helpers.ts +113 -0
- package/internal/framework/_typescript/preact/src/link.tsx +107 -0
- package/internal/framework/_typescript/preact/src/preact.tsx +191 -0
- package/internal/framework/_typescript/preact/tsconfig.json +7 -0
- package/internal/framework/_typescript/react/index.tsx +10 -0
- package/internal/framework/_typescript/react/src/helpers.ts +118 -0
- package/internal/framework/_typescript/react/src/link.tsx +115 -0
- package/internal/framework/_typescript/react/src/react.tsx +299 -0
- package/internal/framework/_typescript/react/tsconfig.json +6 -0
- package/internal/framework/_typescript/solid/index.tsx +10 -0
- package/internal/framework/_typescript/solid/src/helpers.ts +114 -0
- package/internal/framework/_typescript/solid/src/link.tsx +104 -0
- package/internal/framework/_typescript/solid/src/solid.tsx +204 -0
- package/internal/framework/_typescript/solid/tsconfig.json +7 -0
- package/internal/framework/_typescript/vite/tsconfig.json +3 -0
- package/internal/framework/_typescript/vite/vite.ts +93 -0
- package/internal/site/frontend/assets/vorma-banner.webp +0 -0
- package/kit/_typescript/converters/converters.ts +152 -0
- package/kit/_typescript/cookies/cookies.ts +18 -0
- package/kit/_typescript/csrf/csrf.ts +10 -0
- package/kit/_typescript/debounce/debounce.ts +17 -0
- package/kit/_typescript/fmt/fmt.ts +3 -0
- package/kit/_typescript/json/deep_equals.ts +54 -0
- package/kit/_typescript/json/json.ts +3 -0
- package/kit/_typescript/json/search_param_serializer.ts +49 -0
- package/kit/_typescript/json/stringify_stable.ts +43 -0
- package/kit/_typescript/listeners/listeners.ts +16 -0
- package/kit/_typescript/matcher/find_best_match.ts +205 -0
- package/kit/_typescript/matcher/find_nested_matches.ts +357 -0
- package/kit/_typescript/matcher/parse_segments.ts +30 -0
- package/kit/_typescript/matcher/register.ts +271 -0
- package/kit/_typescript/theme/theme.ts +166 -0
- package/kit/_typescript/tsconfig.json +3 -0
- package/kit/_typescript/url/url.ts +132 -0
- package/npm_dist/internal/framework/_typescript/client/index.d.ts +17 -0
- package/npm_dist/internal/framework/_typescript/client/index.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/client/index.js +2489 -0
- package/npm_dist/internal/framework/_typescript/client/index.js.map +7 -0
- package/npm_dist/internal/framework/_typescript/client/src/asset_manager.d.ts +6 -0
- package/npm_dist/internal/framework/_typescript/client/src/asset_manager.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/client/src/client.d.ts +119 -0
- package/npm_dist/internal/framework/_typescript/client/src/client.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/client/src/client_loaders.d.ts +18 -0
- package/npm_dist/internal/framework/_typescript/client/src/client_loaders.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/client/src/component_loader.d.ts +10 -0
- package/npm_dist/internal/framework/_typescript/client/src/component_loader.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/client/src/error_boundary.d.ts +3 -0
- package/npm_dist/internal/framework/_typescript/client/src/error_boundary.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/client/src/events.d.ts +26 -0
- package/npm_dist/internal/framework/_typescript/client/src/events.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/client/src/global_loading_indicator/global_loading_indicator.d.ts +12 -0
- package/npm_dist/internal/framework/_typescript/client/src/global_loading_indicator/global_loading_indicator.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/client/src/hard_reload.d.ts +2 -0
- package/npm_dist/internal/framework/_typescript/client/src/hard_reload.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/client/src/head_elements/head_elements.d.ts +7 -0
- package/npm_dist/internal/framework/_typescript/client/src/head_elements/head_elements.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/client/src/history/history.d.ts +14 -0
- package/npm_dist/internal/framework/_typescript/client/src/history/history.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/client/src/history/npm_history_types.d.ts +84 -0
- package/npm_dist/internal/framework/_typescript/client/src/history/npm_history_types.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/client/src/hmr/hmr.d.ts +3 -0
- package/npm_dist/internal/framework/_typescript/client/src/hmr/hmr.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/client/src/init_client.d.ts +9 -0
- package/npm_dist/internal/framework/_typescript/client/src/init_client.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/client/src/links.d.ts +33 -0
- package/npm_dist/internal/framework/_typescript/client/src/links.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/client/src/redirects/redirects.d.ts +26 -0
- package/npm_dist/internal/framework/_typescript/client/src/redirects/redirects.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/client/src/rendering.d.ts +18 -0
- package/npm_dist/internal/framework/_typescript/client/src/rendering.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/client/src/resolve_public_href.d.ts +2 -0
- package/npm_dist/internal/framework/_typescript/client/src/resolve_public_href.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/client/src/scroll_state_manager.d.ts +22 -0
- package/npm_dist/internal/framework/_typescript/client/src/scroll_state_manager.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/client/src/static_route_defs/route_def_helpers.d.ts +12 -0
- package/npm_dist/internal/framework/_typescript/client/src/static_route_defs/route_def_helpers.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/client/src/ui_lib_impl_helpers/link_components.d.ts +28 -0
- package/npm_dist/internal/framework/_typescript/client/src/ui_lib_impl_helpers/link_components.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/client/src/ui_lib_impl_helpers/route_components.d.ts +18 -0
- package/npm_dist/internal/framework/_typescript/client/src/ui_lib_impl_helpers/route_components.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/client/src/ui_lib_impl_helpers/typed_navigate.d.ts +11 -0
- package/npm_dist/internal/framework/_typescript/client/src/ui_lib_impl_helpers/typed_navigate.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/client/src/utils/errors.d.ts +3 -0
- package/npm_dist/internal/framework/_typescript/client/src/utils/errors.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/client/src/utils/logging.d.ts +3 -0
- package/npm_dist/internal/framework/_typescript/client/src/utils/logging.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/client/src/vorma_app_helpers/vorma_app_helpers.d.ts +119 -0
- package/npm_dist/internal/framework/_typescript/client/src/vorma_app_helpers/vorma_app_helpers.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/client/src/vorma_ctx/vorma_ctx.d.ts +88 -0
- package/npm_dist/internal/framework/_typescript/client/src/vorma_ctx/vorma_ctx.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/client/src/window_focus_revalidation/window_focus_revalidation.d.ts +10 -0
- package/npm_dist/internal/framework/_typescript/client/src/window_focus_revalidation/window_focus_revalidation.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/create/main.d.ts +3 -0
- package/npm_dist/internal/framework/_typescript/create/main.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/preact/index.d.ts +4 -0
- package/npm_dist/internal/framework/_typescript/preact/index.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/preact/index.js +283 -0
- package/npm_dist/internal/framework/_typescript/preact/index.js.map +7 -0
- package/npm_dist/internal/framework/_typescript/preact/src/helpers.d.ts +21 -0
- package/npm_dist/internal/framework/_typescript/preact/src/helpers.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/preact/src/link.d.ts +11 -0
- package/npm_dist/internal/framework/_typescript/preact/src/link.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/preact/src/preact.d.ts +21 -0
- package/npm_dist/internal/framework/_typescript/preact/src/preact.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/react/index.d.ts +4 -0
- package/npm_dist/internal/framework/_typescript/react/index.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/react/index.js +370 -0
- package/npm_dist/internal/framework/_typescript/react/index.js.map +7 -0
- package/npm_dist/internal/framework/_typescript/react/src/helpers.d.ts +21 -0
- package/npm_dist/internal/framework/_typescript/react/src/helpers.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/react/src/link.d.ts +11 -0
- package/npm_dist/internal/framework/_typescript/react/src/link.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/react/src/react.d.ts +20 -0
- package/npm_dist/internal/framework/_typescript/react/src/react.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/solid/index.d.ts +4 -0
- package/npm_dist/internal/framework/_typescript/solid/index.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/solid/index.js +314 -0
- package/npm_dist/internal/framework/_typescript/solid/index.js.map +7 -0
- package/npm_dist/internal/framework/_typescript/solid/src/helpers.d.ts +22 -0
- package/npm_dist/internal/framework/_typescript/solid/src/helpers.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/solid/src/link.d.ts +11 -0
- package/npm_dist/internal/framework/_typescript/solid/src/link.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/solid/src/solid.d.ts +22 -0
- package/npm_dist/internal/framework/_typescript/solid/src/solid.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/vite/vite.d.ts +11 -0
- package/npm_dist/internal/framework/_typescript/vite/vite.d.ts.map +1 -0
- package/npm_dist/internal/framework/_typescript/vite/vite.js +82 -0
- package/npm_dist/internal/framework/_typescript/vite/vite.js.map +7 -0
- package/npm_dist/kit/_typescript/chunk-YBAPNBS2.js +202 -0
- package/npm_dist/kit/_typescript/chunk-YBAPNBS2.js.map +7 -0
- package/npm_dist/kit/_typescript/converters/converters.d.ts +26 -0
- package/npm_dist/kit/_typescript/converters/converters.d.ts.map +1 -0
- package/npm_dist/kit/_typescript/converters/converters.js +99 -0
- package/npm_dist/kit/_typescript/converters/converters.js.map +7 -0
- package/npm_dist/kit/_typescript/cookies/cookies.d.ts +13 -0
- package/npm_dist/kit/_typescript/cookies/cookies.d.ts.map +1 -0
- package/npm_dist/kit/_typescript/cookies/cookies.js +13 -0
- package/npm_dist/kit/_typescript/cookies/cookies.js.map +7 -0
- package/npm_dist/kit/_typescript/csrf/csrf.d.ts +5 -0
- package/npm_dist/kit/_typescript/csrf/csrf.d.ts.map +1 -0
- package/npm_dist/kit/_typescript/csrf/csrf.js +11 -0
- package/npm_dist/kit/_typescript/csrf/csrf.js.map +7 -0
- package/npm_dist/kit/_typescript/debounce/debounce.d.ts +4 -0
- package/npm_dist/kit/_typescript/debounce/debounce.d.ts.map +1 -0
- package/npm_dist/kit/_typescript/debounce/debounce.js +16 -0
- package/npm_dist/kit/_typescript/debounce/debounce.js.map +7 -0
- package/npm_dist/kit/_typescript/fmt/fmt.d.ts +2 -0
- package/npm_dist/kit/_typescript/fmt/fmt.d.ts.map +1 -0
- package/npm_dist/kit/_typescript/fmt/fmt.js +8 -0
- package/npm_dist/kit/_typescript/fmt/fmt.js.map +7 -0
- package/npm_dist/kit/_typescript/json/deep_equals.d.ts +7 -0
- package/npm_dist/kit/_typescript/json/deep_equals.d.ts.map +1 -0
- package/npm_dist/kit/_typescript/json/json.d.ts +4 -0
- package/npm_dist/kit/_typescript/json/json.d.ts.map +1 -0
- package/npm_dist/kit/_typescript/json/json.js +110 -0
- package/npm_dist/kit/_typescript/json/json.js.map +7 -0
- package/npm_dist/kit/_typescript/json/search_param_serializer.d.ts +2 -0
- package/npm_dist/kit/_typescript/json/search_param_serializer.d.ts.map +1 -0
- package/npm_dist/kit/_typescript/json/stringify_stable.d.ts +7 -0
- package/npm_dist/kit/_typescript/json/stringify_stable.d.ts.map +1 -0
- package/npm_dist/kit/_typescript/listeners/listeners.d.ts +2 -0
- package/npm_dist/kit/_typescript/listeners/listeners.d.ts.map +1 -0
- package/npm_dist/kit/_typescript/listeners/listeners.js +20 -0
- package/npm_dist/kit/_typescript/listeners/listeners.js.map +7 -0
- package/npm_dist/kit/_typescript/matcher/find_best_match.d.ts +10 -0
- package/npm_dist/kit/_typescript/matcher/find_best_match.d.ts.map +1 -0
- package/npm_dist/kit/_typescript/matcher/find_best_match.js +146 -0
- package/npm_dist/kit/_typescript/matcher/find_best_match.js.map +7 -0
- package/npm_dist/kit/_typescript/matcher/find_nested_matches.d.ts +14 -0
- package/npm_dist/kit/_typescript/matcher/find_nested_matches.d.ts.map +1 -0
- package/npm_dist/kit/_typescript/matcher/find_nested_matches.js +248 -0
- package/npm_dist/kit/_typescript/matcher/find_nested_matches.js.map +7 -0
- package/npm_dist/kit/_typescript/matcher/parse_segments.d.ts +2 -0
- package/npm_dist/kit/_typescript/matcher/parse_segments.d.ts.map +1 -0
- package/npm_dist/kit/_typescript/matcher/register.d.ts +54 -0
- package/npm_dist/kit/_typescript/matcher/register.d.ts.map +1 -0
- package/npm_dist/kit/_typescript/matcher/register.js +21 -0
- package/npm_dist/kit/_typescript/matcher/register.js.map +7 -0
- package/npm_dist/kit/_typescript/theme/theme.d.ts +23 -0
- package/npm_dist/kit/_typescript/theme/theme.d.ts.map +1 -0
- package/npm_dist/kit/_typescript/theme/theme.js +122 -0
- package/npm_dist/kit/_typescript/theme/theme.js.map +7 -0
- package/npm_dist/kit/_typescript/url/url.d.ts +30 -0
- package/npm_dist/kit/_typescript/url/url.d.ts.map +1 -0
- package/npm_dist/kit/_typescript/url/url.js +100 -0
- package/npm_dist/kit/_typescript/url/url.js.map +7 -0
- package/package.json +135 -3
- package/tsconfig.base.json +17 -0
- package/index.js +0 -1
|
@@ -0,0 +1,314 @@
|
|
|
1
|
+
// internal/framework/_typescript/solid/src/helpers.ts
|
|
2
|
+
import { createMemo as createMemo2 } from "solid-js";
|
|
3
|
+
import {
|
|
4
|
+
__registerClientLoaderPattern,
|
|
5
|
+
__runClientLoadersAfterHMRUpdate,
|
|
6
|
+
__vormaClientGlobal
|
|
7
|
+
} from "vorma/client";
|
|
8
|
+
|
|
9
|
+
// internal/framework/_typescript/solid/src/solid.tsx
|
|
10
|
+
import { createComponent as _$createComponent } from "solid-js/web";
|
|
11
|
+
import { mergeProps as _$mergeProps } from "solid-js/web";
|
|
12
|
+
import { batch, createEffect, createMemo, createRenderEffect, createSignal, Show } from "solid-js";
|
|
13
|
+
import { Dynamic } from "solid-js/web";
|
|
14
|
+
import { __applyScrollState, addLocationListener, addRouteChangeListener, __vormaClientGlobal as ctx, getLocation, getRouterData } from "vorma/client";
|
|
15
|
+
var [latestEvent, setLatestEvent] = createSignal(null);
|
|
16
|
+
var [loadersData, setLoadersData] = createSignal(ctx.get("loadersData"));
|
|
17
|
+
var [clientLoadersData, setClientLoadersData] = createSignal(ctx.get("clientLoadersData"));
|
|
18
|
+
var [routerData, setRouterData] = createSignal(getRouterData());
|
|
19
|
+
var [outermostErrorIdx, setOutermostErrorIdx] = createSignal(ctx.get("outermostErrorIdx"));
|
|
20
|
+
var [outermostError, setOutermostError] = createSignal(ctx.get("outermostError"));
|
|
21
|
+
var [activeComponents, setActiveComponents] = createSignal(ctx.get("activeComponents"));
|
|
22
|
+
var [activeErrorBoundary, setActiveErrorBoundary] = createSignal(ctx.get("activeErrorBoundary"));
|
|
23
|
+
var [importURLs, setImportURLs] = createSignal(ctx.get("importURLs"));
|
|
24
|
+
var [exportKeys, setExportKeys] = createSignal(ctx.get("exportKeys"));
|
|
25
|
+
var isInited = false;
|
|
26
|
+
function initUIListeners() {
|
|
27
|
+
if (isInited) return;
|
|
28
|
+
isInited = true;
|
|
29
|
+
addRouteChangeListener((e) => {
|
|
30
|
+
batch(() => {
|
|
31
|
+
setLatestEvent(e);
|
|
32
|
+
setLoadersData(ctx.get("loadersData"));
|
|
33
|
+
setClientLoadersData(ctx.get("clientLoadersData"));
|
|
34
|
+
setRouterData(getRouterData());
|
|
35
|
+
setOutermostErrorIdx(ctx.get("outermostErrorIdx"));
|
|
36
|
+
setOutermostError(ctx.get("outermostError"));
|
|
37
|
+
setActiveComponents(ctx.get("activeComponents"));
|
|
38
|
+
setActiveErrorBoundary(ctx.get("activeErrorBoundary"));
|
|
39
|
+
setImportURLs(ctx.get("importURLs"));
|
|
40
|
+
setExportKeys(ctx.get("exportKeys"));
|
|
41
|
+
});
|
|
42
|
+
});
|
|
43
|
+
addLocationListener(() => {
|
|
44
|
+
setLocation(getLocation());
|
|
45
|
+
});
|
|
46
|
+
}
|
|
47
|
+
var [location, setLocation] = createSignal(getLocation());
|
|
48
|
+
function VormaRootOutlet(props) {
|
|
49
|
+
const idx = props.idx ?? 0;
|
|
50
|
+
if (idx === 0) {
|
|
51
|
+
initUIListeners();
|
|
52
|
+
batch(() => {
|
|
53
|
+
setLoadersData(ctx.get("loadersData"));
|
|
54
|
+
setClientLoadersData(ctx.get("clientLoadersData"));
|
|
55
|
+
setRouterData(getRouterData());
|
|
56
|
+
setOutermostErrorIdx(ctx.get("outermostErrorIdx"));
|
|
57
|
+
setOutermostError(ctx.get("outermostError"));
|
|
58
|
+
setActiveComponents(ctx.get("activeComponents"));
|
|
59
|
+
setActiveErrorBoundary(ctx.get("activeErrorBoundary"));
|
|
60
|
+
setImportURLs(ctx.get("importURLs"));
|
|
61
|
+
setExportKeys(ctx.get("exportKeys"));
|
|
62
|
+
});
|
|
63
|
+
}
|
|
64
|
+
const [currentImportURL, setCurrentImportURL] = createSignal(importURLs()?.[idx]);
|
|
65
|
+
const [currentExportKey, setCurrentExportKey] = createSignal(exportKeys()?.[idx]);
|
|
66
|
+
createEffect(() => {
|
|
67
|
+
if (!currentImportURL()) {
|
|
68
|
+
return;
|
|
69
|
+
}
|
|
70
|
+
const e = latestEvent();
|
|
71
|
+
if (!e) {
|
|
72
|
+
return;
|
|
73
|
+
}
|
|
74
|
+
const newCurrentImportURL = importURLs()?.[idx];
|
|
75
|
+
const newCurrentExportKey = exportKeys()?.[idx];
|
|
76
|
+
if (currentImportURL() !== newCurrentImportURL) {
|
|
77
|
+
setCurrentImportURL(newCurrentImportURL);
|
|
78
|
+
}
|
|
79
|
+
if (currentExportKey() !== newCurrentExportKey) {
|
|
80
|
+
setCurrentExportKey(newCurrentExportKey);
|
|
81
|
+
}
|
|
82
|
+
});
|
|
83
|
+
createRenderEffect(() => {
|
|
84
|
+
const e = latestEvent();
|
|
85
|
+
if (!e || idx !== 0) {
|
|
86
|
+
return;
|
|
87
|
+
}
|
|
88
|
+
window.requestAnimationFrame(() => {
|
|
89
|
+
__applyScrollState(e.detail.__scrollState);
|
|
90
|
+
});
|
|
91
|
+
});
|
|
92
|
+
const isErrorIdxMemo = createMemo(() => {
|
|
93
|
+
return idx === outermostErrorIdx();
|
|
94
|
+
});
|
|
95
|
+
const currentCompMemo = createMemo(() => {
|
|
96
|
+
if (isErrorIdxMemo()) {
|
|
97
|
+
return null;
|
|
98
|
+
}
|
|
99
|
+
currentImportURL();
|
|
100
|
+
currentExportKey();
|
|
101
|
+
return activeComponents()?.[idx];
|
|
102
|
+
});
|
|
103
|
+
const shouldFallbackOutletMemo = createMemo(() => {
|
|
104
|
+
if (isErrorIdxMemo() || currentCompMemo()) {
|
|
105
|
+
return false;
|
|
106
|
+
}
|
|
107
|
+
return idx + 1 < loadersData().length;
|
|
108
|
+
});
|
|
109
|
+
const errorCompMemo = createMemo(() => {
|
|
110
|
+
if (!isErrorIdxMemo()) {
|
|
111
|
+
return null;
|
|
112
|
+
}
|
|
113
|
+
return activeErrorBoundary();
|
|
114
|
+
});
|
|
115
|
+
const remountKeyNext = createMemo(() => `${importURLs()[idx + 1]}|${exportKeys()[idx + 1]}`);
|
|
116
|
+
const Outlet = (localProps) => _$createComponent(Show, {
|
|
117
|
+
get when() {
|
|
118
|
+
return remountKeyNext();
|
|
119
|
+
},
|
|
120
|
+
keyed: true,
|
|
121
|
+
get children() {
|
|
122
|
+
return _$createComponent(VormaRootOutlet, _$mergeProps(localProps, props, {
|
|
123
|
+
idx: idx + 1
|
|
124
|
+
}));
|
|
125
|
+
}
|
|
126
|
+
});
|
|
127
|
+
return [_$createComponent(Show, {
|
|
128
|
+
get when() {
|
|
129
|
+
return currentCompMemo();
|
|
130
|
+
},
|
|
131
|
+
get children() {
|
|
132
|
+
return _$createComponent(Dynamic, {
|
|
133
|
+
get component() {
|
|
134
|
+
return currentCompMemo();
|
|
135
|
+
},
|
|
136
|
+
idx,
|
|
137
|
+
Outlet
|
|
138
|
+
});
|
|
139
|
+
}
|
|
140
|
+
}), _$createComponent(Show, {
|
|
141
|
+
get when() {
|
|
142
|
+
return shouldFallbackOutletMemo();
|
|
143
|
+
},
|
|
144
|
+
get children() {
|
|
145
|
+
return _$createComponent(Outlet, {});
|
|
146
|
+
}
|
|
147
|
+
}), _$createComponent(Show, {
|
|
148
|
+
get when() {
|
|
149
|
+
return isErrorIdxMemo();
|
|
150
|
+
},
|
|
151
|
+
get children() {
|
|
152
|
+
return _$createComponent(Show, {
|
|
153
|
+
get when() {
|
|
154
|
+
return errorCompMemo();
|
|
155
|
+
},
|
|
156
|
+
get fallback() {
|
|
157
|
+
return `Error: ${outermostError() || "unknown"}`;
|
|
158
|
+
},
|
|
159
|
+
get children() {
|
|
160
|
+
return _$createComponent(Dynamic, {
|
|
161
|
+
get component() {
|
|
162
|
+
return errorCompMemo();
|
|
163
|
+
},
|
|
164
|
+
get error() {
|
|
165
|
+
return outermostError();
|
|
166
|
+
}
|
|
167
|
+
});
|
|
168
|
+
}
|
|
169
|
+
});
|
|
170
|
+
}
|
|
171
|
+
})];
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
// internal/framework/_typescript/solid/src/helpers.ts
|
|
175
|
+
function makeTypedUseRouterData() {
|
|
176
|
+
return (() => routerData);
|
|
177
|
+
}
|
|
178
|
+
function makeTypedUseLoaderData() {
|
|
179
|
+
return function useLoaderData(props) {
|
|
180
|
+
return createMemo2(() => {
|
|
181
|
+
return loadersData()[props.idx];
|
|
182
|
+
});
|
|
183
|
+
};
|
|
184
|
+
}
|
|
185
|
+
function makeTypedUsePatternLoaderData() {
|
|
186
|
+
return function usePatternLoaderData(pattern) {
|
|
187
|
+
const idx = createMemo2(() => {
|
|
188
|
+
const matchedPatterns = routerData().matchedPatterns;
|
|
189
|
+
return matchedPatterns.findIndex((p) => p === pattern);
|
|
190
|
+
});
|
|
191
|
+
const loaderData = createMemo2(() => {
|
|
192
|
+
const index = idx();
|
|
193
|
+
if (index === -1) {
|
|
194
|
+
return void 0;
|
|
195
|
+
}
|
|
196
|
+
return loadersData()[index];
|
|
197
|
+
});
|
|
198
|
+
return loaderData;
|
|
199
|
+
};
|
|
200
|
+
}
|
|
201
|
+
function makeTypedAddClientLoader() {
|
|
202
|
+
const m = __vormaClientGlobal.get("patternToWaitFnMap");
|
|
203
|
+
return function addClientLoader(props) {
|
|
204
|
+
const p = props.pattern;
|
|
205
|
+
const fn = props.clientLoader;
|
|
206
|
+
__registerClientLoaderPattern(p).catch((error) => {
|
|
207
|
+
console.error("Failed to register client loader pattern:", error);
|
|
208
|
+
});
|
|
209
|
+
m[p] = fn;
|
|
210
|
+
if (import.meta.env.DEV && props.reRunOnModuleChange) {
|
|
211
|
+
__runClientLoadersAfterHMRUpdate(props.reRunOnModuleChange, p);
|
|
212
|
+
}
|
|
213
|
+
const useClientLoaderData = (props2) => {
|
|
214
|
+
return createMemo2(() => {
|
|
215
|
+
if (props2) {
|
|
216
|
+
return clientLoadersData()[props2.idx];
|
|
217
|
+
}
|
|
218
|
+
const matched = routerData().matchedPatterns;
|
|
219
|
+
const idx = matched.findIndex((pattern) => pattern === p);
|
|
220
|
+
if (idx === -1) return void 0;
|
|
221
|
+
return clientLoadersData()[idx];
|
|
222
|
+
});
|
|
223
|
+
};
|
|
224
|
+
return useClientLoaderData;
|
|
225
|
+
};
|
|
226
|
+
}
|
|
227
|
+
|
|
228
|
+
// internal/framework/_typescript/solid/src/link.tsx
|
|
229
|
+
import { template as _$template } from "solid-js/web";
|
|
230
|
+
import { createComponent as _$createComponent2 } from "solid-js/web";
|
|
231
|
+
import { insert as _$insert } from "solid-js/web";
|
|
232
|
+
import { spread as _$spread } from "solid-js/web";
|
|
233
|
+
import { mergeProps as _$mergeProps2 } from "solid-js/web";
|
|
234
|
+
import { createMemo as createMemo3, mergeProps, splitProps } from "solid-js";
|
|
235
|
+
import { __makeFinalLinkProps, __resolvePath } from "vorma/client";
|
|
236
|
+
var _tmpl$ = /* @__PURE__ */ _$template(`<a>`);
|
|
237
|
+
function VormaLink(props) {
|
|
238
|
+
const finalLinkProps = createMemo3(() => __makeFinalLinkProps(props));
|
|
239
|
+
const [, rest] = splitProps(props, ["prefetch", "scrollToTop", "replace", "state"]);
|
|
240
|
+
return (() => {
|
|
241
|
+
var _el$ = _tmpl$();
|
|
242
|
+
_$spread(_el$, _$mergeProps2({
|
|
243
|
+
get ["data-external"]() {
|
|
244
|
+
return finalLinkProps().dataExternal;
|
|
245
|
+
}
|
|
246
|
+
}, rest, {
|
|
247
|
+
get onPointerEnter() {
|
|
248
|
+
return finalLinkProps().onPointerEnter;
|
|
249
|
+
},
|
|
250
|
+
get onFocus() {
|
|
251
|
+
return finalLinkProps().onFocus;
|
|
252
|
+
},
|
|
253
|
+
get onPointerLeave() {
|
|
254
|
+
return finalLinkProps().onPointerLeave;
|
|
255
|
+
},
|
|
256
|
+
get onBlur() {
|
|
257
|
+
return finalLinkProps().onBlur;
|
|
258
|
+
},
|
|
259
|
+
get onTouchCancel() {
|
|
260
|
+
return finalLinkProps().onTouchCancel;
|
|
261
|
+
},
|
|
262
|
+
get onClick() {
|
|
263
|
+
return finalLinkProps().onClick;
|
|
264
|
+
}
|
|
265
|
+
}), false, true);
|
|
266
|
+
_$insert(_el$, () => props.children);
|
|
267
|
+
return _el$;
|
|
268
|
+
})();
|
|
269
|
+
}
|
|
270
|
+
function makeTypedLink(vormaAppConfig, defaultProps) {
|
|
271
|
+
const TypedLink = (props) => {
|
|
272
|
+
const merged = mergeProps(defaultProps || {}, props);
|
|
273
|
+
const [local, linkProps] = splitProps(merged, ["pattern", "params", "splatValues", "search", "hash", "state"]);
|
|
274
|
+
const href = createMemo3(() => {
|
|
275
|
+
const basePath = __resolvePath({
|
|
276
|
+
vormaAppConfig,
|
|
277
|
+
type: "loader",
|
|
278
|
+
props: {
|
|
279
|
+
pattern: local.pattern,
|
|
280
|
+
...local.params && {
|
|
281
|
+
params: local.params
|
|
282
|
+
},
|
|
283
|
+
...local.splatValues && {
|
|
284
|
+
splatValues: local.splatValues
|
|
285
|
+
}
|
|
286
|
+
}
|
|
287
|
+
});
|
|
288
|
+
const url = new URL(basePath, window.location.origin);
|
|
289
|
+
if (local.search !== void 0) url.search = local.search;
|
|
290
|
+
if (local.hash !== void 0) url.hash = local.hash;
|
|
291
|
+
return url.href;
|
|
292
|
+
});
|
|
293
|
+
return _$createComponent2(VormaLink, _$mergeProps2(linkProps, {
|
|
294
|
+
get href() {
|
|
295
|
+
return href();
|
|
296
|
+
},
|
|
297
|
+
get state() {
|
|
298
|
+
return local.state;
|
|
299
|
+
}
|
|
300
|
+
}));
|
|
301
|
+
};
|
|
302
|
+
return TypedLink;
|
|
303
|
+
}
|
|
304
|
+
export {
|
|
305
|
+
VormaLink,
|
|
306
|
+
VormaRootOutlet,
|
|
307
|
+
location,
|
|
308
|
+
makeTypedAddClientLoader,
|
|
309
|
+
makeTypedLink,
|
|
310
|
+
makeTypedUseLoaderData,
|
|
311
|
+
makeTypedUsePatternLoaderData,
|
|
312
|
+
makeTypedUseRouterData
|
|
313
|
+
};
|
|
314
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../../../internal/framework/_typescript/solid/src/helpers.ts", "../../../../../internal/framework/_typescript/solid/src/solid.tsx", "../../../../../internal/framework/_typescript/solid/src/link.tsx"],
|
|
4
|
+
"sourcesContent": ["/// <reference types=\"vite/client\" />\n\nimport { createMemo, type Accessor } from \"solid-js\";\nimport type { JSX } from \"solid-js/jsx-runtime\";\nimport {\n\t__registerClientLoaderPattern,\n\t__runClientLoadersAfterHMRUpdate,\n\t__vormaClientGlobal,\n\ttype ClientLoaderAwaitedServerData,\n\ttype ParamsForPattern,\n\ttype UseRouterDataFunction,\n\ttype VormaAppBase,\n\ttype VormaLoaderOutput,\n\ttype VormaLoaderPattern,\n\ttype VormaRouteGeneric,\n\ttype VormaRoutePropsGeneric,\n} from \"vorma/client\";\nimport { clientLoadersData, loadersData, routerData } from \"./solid.tsx\";\n\nexport type VormaRouteProps<\n\tApp extends VormaAppBase = any,\n\tPattern extends VormaLoaderPattern<App> = string,\n> = VormaRoutePropsGeneric<JSX.Element, App, Pattern>;\n\nexport type VormaRoute<\n\tApp extends VormaAppBase = any,\n\tPattern extends VormaLoaderPattern<App> = string,\n> = VormaRouteGeneric<JSX.Element, App, Pattern>;\n\nexport function makeTypedUseRouterData<App extends VormaAppBase>() {\n\treturn (() => routerData) as UseRouterDataFunction<App, true>;\n}\n\nexport function makeTypedUseLoaderData<App extends VormaAppBase>() {\n\treturn function useLoaderData<Pattern extends VormaLoaderPattern<App>>(\n\t\tprops: VormaRouteProps<App, Pattern>,\n\t): Accessor<VormaLoaderOutput<App, Pattern>> {\n\t\treturn createMemo(() => {\n\t\t\treturn loadersData()[props.idx];\n\t\t});\n\t};\n}\n\nexport function makeTypedUsePatternLoaderData<App extends VormaAppBase>() {\n\treturn function usePatternLoaderData<\n\t\tPattern extends VormaLoaderPattern<App>,\n\t>(pattern: Pattern): Accessor<VormaLoaderOutput<App, Pattern> | undefined> {\n\t\tconst idx = createMemo(() => {\n\t\t\tconst matchedPatterns = routerData().matchedPatterns;\n\t\t\treturn matchedPatterns.findIndex((p) => p === pattern);\n\t\t});\n\t\tconst loaderData = createMemo(() => {\n\t\t\tconst index = idx();\n\t\t\tif (index === -1) {\n\t\t\t\treturn undefined;\n\t\t\t}\n\t\t\treturn loadersData()[index];\n\t\t});\n\t\treturn loaderData;\n\t};\n}\n\nexport function makeTypedAddClientLoader<App extends VormaAppBase>() {\n\tconst m = __vormaClientGlobal.get(\"patternToWaitFnMap\");\n\treturn function addClientLoader<\n\t\tPattern extends VormaLoaderPattern<App>,\n\t\tLoaderData extends VormaLoaderOutput<App, Pattern>,\n\t\tT = any,\n\t>(props: {\n\t\tpattern: Pattern;\n\t\tclientLoader: (props: {\n\t\t\tparams: Record<ParamsForPattern<App, Pattern>, string>;\n\t\t\tsplatValues: string[];\n\t\t\tserverDataPromise: Promise<\n\t\t\t\tClientLoaderAwaitedServerData<App[\"rootData\"], LoaderData>\n\t\t\t>;\n\t\t\tsignal: AbortSignal;\n\t\t}) => Promise<T>;\n\t\treRunOnModuleChange?: ImportMeta;\n\t}) {\n\t\tconst p = props.pattern;\n\t\tconst fn = props.clientLoader;\n\n\t\t__registerClientLoaderPattern(p as string).catch((error) => {\n\t\t\tconsole.error(\"Failed to register client loader pattern:\", error);\n\t\t});\n\t\t(m as any)[p] = fn;\n\n\t\tif (import.meta.env.DEV && props.reRunOnModuleChange) {\n\t\t\t__runClientLoadersAfterHMRUpdate(props.reRunOnModuleChange, p);\n\t\t}\n\n\t\ttype Res = Awaited<ReturnType<typeof fn>>;\n\n\t\tconst useClientLoaderData = (\n\t\t\tprops?: VormaRouteProps<App, Pattern>,\n\t\t): Accessor<Res | undefined> => {\n\t\t\treturn createMemo(() => {\n\t\t\t\tif (props) {\n\t\t\t\t\treturn clientLoadersData()[props.idx];\n\t\t\t\t}\n\t\t\t\tconst matched = routerData().matchedPatterns;\n\t\t\t\tconst idx = matched.findIndex((pattern) => pattern === p);\n\t\t\t\tif (idx === -1) return undefined;\n\t\t\t\treturn clientLoadersData()[idx];\n\t\t\t});\n\t\t};\n\n\t\treturn useClientLoaderData as {\n\t\t\t(props: VormaRouteProps<App, Pattern>): Accessor<Res>;\n\t\t\t(): Accessor<Res | undefined>;\n\t\t};\n\t};\n}\n", "import {\n\tbatch,\n\tcreateEffect,\n\tcreateMemo,\n\tcreateRenderEffect,\n\tcreateSignal,\n\ttype JSX,\n\tShow,\n} from \"solid-js\";\nimport { Dynamic } from \"solid-js/web\";\nimport {\n\t__applyScrollState,\n\taddLocationListener,\n\taddRouteChangeListener,\n\t__vormaClientGlobal as ctx,\n\tgetLocation,\n\tgetRouterData,\n\ttype RouteChangeEvent,\n} from \"vorma/client\";\n\n/////////////////////////////////////////////////////////////////////\n/////// CORE SETUP\n/////////////////////////////////////////////////////////////////////\n\nconst [latestEvent, setLatestEvent] = createSignal<RouteChangeEvent | null>(\n\tnull,\n);\nconst [loadersData, setLoadersData] = createSignal(ctx.get(\"loadersData\"));\nconst [clientLoadersData, setClientLoadersData] = createSignal(\n\tctx.get(\"clientLoadersData\"),\n);\nconst [routerData, setRouterData] = createSignal(getRouterData());\nconst [outermostErrorIdx, setOutermostErrorIdx] = createSignal(\n\tctx.get(\"outermostErrorIdx\"),\n);\nconst [outermostError, setOutermostError] = createSignal(\n\tctx.get(\"outermostError\"),\n);\nconst [activeComponents, setActiveComponents] = createSignal(\n\tctx.get(\"activeComponents\"),\n);\nconst [activeErrorBoundary, setActiveErrorBoundary] = createSignal(\n\tctx.get(\"activeErrorBoundary\"),\n);\nconst [importURLs, setImportURLs] = createSignal(ctx.get(\"importURLs\"));\nconst [exportKeys, setExportKeys] = createSignal(ctx.get(\"exportKeys\"));\n\nexport { clientLoadersData, loadersData, routerData };\n\nlet isInited = false;\n\nfunction initUIListeners() {\n\tif (isInited) return;\n\tisInited = true;\n\n\taddRouteChangeListener((e) => {\n\t\tbatch(() => {\n\t\t\tsetLatestEvent(e);\n\t\t\tsetLoadersData(ctx.get(\"loadersData\"));\n\t\t\tsetClientLoadersData(ctx.get(\"clientLoadersData\"));\n\t\t\tsetRouterData(getRouterData());\n\t\t\tsetOutermostErrorIdx(ctx.get(\"outermostErrorIdx\"));\n\t\t\tsetOutermostError(ctx.get(\"outermostError\"));\n\t\t\tsetActiveComponents(ctx.get(\"activeComponents\"));\n\t\t\tsetActiveErrorBoundary(ctx.get(\"activeErrorBoundary\"));\n\t\t\tsetImportURLs(ctx.get(\"importURLs\"));\n\t\t\tsetExportKeys(ctx.get(\"exportKeys\"));\n\t\t});\n\t});\n\n\taddLocationListener(() => {\n\t\tsetLocation(getLocation());\n\t});\n}\n\nconst [location, setLocation] = createSignal(getLocation());\n\nexport { location };\n\n/////////////////////////////////////////////////////////////////////\n/////// COMPONENT\n/////////////////////////////////////////////////////////////////////\n\nexport function VormaRootOutlet(props: { idx?: number }): JSX.Element {\n\tconst idx = props.idx ?? 0;\n\n\tif (idx === 0) {\n\t\tinitUIListeners();\n\n\t\tbatch(() => {\n\t\t\tsetLoadersData(ctx.get(\"loadersData\"));\n\t\t\tsetClientLoadersData(ctx.get(\"clientLoadersData\"));\n\t\t\tsetRouterData(getRouterData());\n\t\t\tsetOutermostErrorIdx(ctx.get(\"outermostErrorIdx\"));\n\t\t\tsetOutermostError(ctx.get(\"outermostError\"));\n\t\t\tsetActiveComponents(ctx.get(\"activeComponents\"));\n\t\t\tsetActiveErrorBoundary(ctx.get(\"activeErrorBoundary\"));\n\t\t\tsetImportURLs(ctx.get(\"importURLs\"));\n\t\t\tsetExportKeys(ctx.get(\"exportKeys\"));\n\t\t});\n\t}\n\n\tconst [currentImportURL, setCurrentImportURL] = createSignal(\n\t\timportURLs()?.[idx],\n\t);\n\tconst [currentExportKey, setCurrentExportKey] = createSignal(\n\t\texportKeys()?.[idx],\n\t);\n\n\tcreateEffect(() => {\n\t\tif (!currentImportURL()) {\n\t\t\treturn;\n\t\t}\n\t\tconst e = latestEvent();\n\t\tif (!e) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst newCurrentImportURL = importURLs()?.[idx];\n\t\tconst newCurrentExportKey = exportKeys()?.[idx];\n\n\t\tif (currentImportURL() !== newCurrentImportURL) {\n\t\t\tsetCurrentImportURL(newCurrentImportURL);\n\t\t}\n\t\tif (currentExportKey() !== newCurrentExportKey) {\n\t\t\tsetCurrentExportKey(newCurrentExportKey);\n\t\t}\n\t});\n\n\tcreateRenderEffect(() => {\n\t\tconst e = latestEvent();\n\t\tif (!e || idx !== 0) {\n\t\t\treturn;\n\t\t}\n\t\twindow.requestAnimationFrame(() => {\n\t\t\t__applyScrollState(e.detail.__scrollState);\n\t\t});\n\t});\n\n\tconst isErrorIdxMemo = createMemo(() => {\n\t\treturn idx === outermostErrorIdx();\n\t});\n\n\tconst currentCompMemo = createMemo(() => {\n\t\tif (isErrorIdxMemo()) {\n\t\t\treturn null;\n\t\t}\n\t\tcurrentImportURL();\n\t\tcurrentExportKey();\n\t\treturn activeComponents()?.[idx];\n\t});\n\n\tconst shouldFallbackOutletMemo = createMemo(() => {\n\t\tif (isErrorIdxMemo() || currentCompMemo()) {\n\t\t\treturn false;\n\t\t}\n\t\treturn idx + 1 < loadersData().length;\n\t});\n\n\tconst errorCompMemo = createMemo(() => {\n\t\tif (!isErrorIdxMemo()) {\n\t\t\treturn null;\n\t\t}\n\t\treturn activeErrorBoundary();\n\t});\n\n\tconst remountKeyNext = createMemo(\n\t\t() => `${importURLs()[idx + 1]}|${exportKeys()[idx + 1]}`,\n\t);\n\n\tconst Outlet = (localProps: Record<string, any> | undefined) => (\n\t\t<Show when={remountKeyNext()} keyed>\n\t\t\t<VormaRootOutlet {...localProps} {...props} idx={idx + 1} />\n\t\t</Show>\n\t);\n\n\treturn (\n\t\t<>\n\t\t\t<Show when={currentCompMemo()}>\n\t\t\t\t<Dynamic\n\t\t\t\t\tcomponent={currentCompMemo()}\n\t\t\t\t\tidx={idx}\n\t\t\t\t\tOutlet={Outlet}\n\t\t\t\t/>\n\t\t\t</Show>\n\n\t\t\t<Show when={shouldFallbackOutletMemo()}>\n\t\t\t\t<Outlet />\n\t\t\t</Show>\n\n\t\t\t<Show when={isErrorIdxMemo()}>\n\t\t\t\t<Show\n\t\t\t\t\twhen={errorCompMemo()}\n\t\t\t\t\tfallback={`Error: ${outermostError() || \"unknown\"}`}\n\t\t\t\t>\n\t\t\t\t\t<Dynamic\n\t\t\t\t\t\tcomponent={errorCompMemo()}\n\t\t\t\t\t\terror={outermostError()}\n\t\t\t\t\t/>\n\t\t\t\t</Show>\n\t\t\t</Show>\n\t\t</>\n\t);\n}\n", "import { createMemo, mergeProps, splitProps, type JSX } from \"solid-js\";\nimport type {\n\tExtractApp,\n\tPermissivePatternBasedProps,\n\tVormaAppBase,\n\tVormaLoaderPattern,\n} from \"vorma/client\";\nimport {\n\t__makeFinalLinkProps,\n\t__resolvePath,\n\ttype VormaAppConfig,\n\ttype VormaLinkPropsBase,\n} from \"vorma/client\";\n\nexport function VormaLink(\n\tprops: JSX.AnchorHTMLAttributes<HTMLAnchorElement> &\n\t\tVormaLinkPropsBase<\n\t\t\tJSX.CustomEventHandlersCamelCase<HTMLAnchorElement>[\"onClick\"]\n\t\t>,\n) {\n\tconst finalLinkProps = createMemo(() => __makeFinalLinkProps(props));\n\tconst [, rest] = splitProps(props, [\n\t\t\"prefetch\",\n\t\t\"scrollToTop\",\n\t\t\"replace\",\n\t\t\"state\",\n\t]);\n\n\treturn (\n\t\t<a\n\t\t\tdata-external={finalLinkProps().dataExternal}\n\t\t\t{...rest}\n\t\t\tonPointerEnter={finalLinkProps().onPointerEnter}\n\t\t\tonFocus={finalLinkProps().onFocus}\n\t\t\tonPointerLeave={finalLinkProps().onPointerLeave}\n\t\t\tonBlur={finalLinkProps().onBlur}\n\t\t\tonTouchCancel={finalLinkProps().onTouchCancel}\n\t\t\tonClick={finalLinkProps().onClick}\n\t\t>\n\t\t\t{props.children}\n\t\t</a>\n\t);\n}\n\ntype TypedVormaLinkProps<\n\tApp extends VormaAppBase,\n\tPattern extends VormaLoaderPattern<App> = VormaLoaderPattern<App>,\n> = Omit<JSX.AnchorHTMLAttributes<HTMLAnchorElement>, \"href\" | \"pattern\"> &\n\tVormaLinkPropsBase<\n\t\tJSX.CustomEventHandlersCamelCase<HTMLAnchorElement>[\"onClick\"]\n\t> &\n\tPermissivePatternBasedProps<App, Pattern> & {\n\t\tsearch?: string;\n\t\thash?: string;\n\t};\n\nexport function makeTypedLink<C extends VormaAppConfig>(\n\tvormaAppConfig: C,\n\tdefaultProps?: Partial<\n\t\tOmit<\n\t\t\tTypedVormaLinkProps<ExtractApp<C>>,\n\t\t\t\"pattern\" | \"params\" | \"splatValues\"\n\t\t>\n\t>,\n) {\n\ttype App = ExtractApp<C>;\n\n\tconst TypedLink = <Pattern extends VormaLoaderPattern<App>>(\n\t\tprops: TypedVormaLinkProps<App, Pattern>,\n\t) => {\n\t\tconst merged = mergeProps(defaultProps || {}, props);\n\n\t\tconst [local, linkProps] = splitProps(merged as any, [\n\t\t\t\"pattern\",\n\t\t\t\"params\",\n\t\t\t\"splatValues\",\n\t\t\t\"search\",\n\t\t\t\"hash\",\n\t\t\t\"state\",\n\t\t]);\n\n\t\tconst href = createMemo(() => {\n\t\t\tconst basePath = __resolvePath({\n\t\t\t\tvormaAppConfig,\n\t\t\t\ttype: \"loader\",\n\t\t\t\tprops: {\n\t\t\t\t\tpattern: local.pattern,\n\t\t\t\t\t...(local.params && { params: local.params }),\n\t\t\t\t\t...(local.splatValues && {\n\t\t\t\t\t\tsplatValues: local.splatValues,\n\t\t\t\t\t}),\n\t\t\t\t},\n\t\t\t});\n\t\t\tconst url = new URL(basePath, window.location.origin);\n\t\t\tif (local.search !== undefined) url.search = local.search;\n\t\t\tif (local.hash !== undefined) url.hash = local.hash;\n\t\t\treturn url.href;\n\t\t});\n\n\t\treturn <VormaLink {...linkProps} href={href()} state={local.state} />;\n\t};\n\n\treturn TypedLink;\n}\n"],
|
|
5
|
+
"mappings": ";AAEA,SAAS,cAAAA,mBAAiC;AAE1C;AAAA,EACC;AAAA,EACA;AAAA,EACA;AAAA,OASM;;;;;AChBP,SACCC,OACAC,cACAC,YACAC,oBACAC,cAEAC,YACM;AACP,SAASC,eAAe;AACxB,SACCC,oBACAC,qBACAC,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A,IAC/BC,gBAAa;AAAA,eAAEX,eAAe,EAAEW;MAAa;MAAA,IAC7CC,UAAO;AAAA,eAAEZ,eAAe,EAAEY;MAAO;IAAA,CAAA,GAAA,OAAA,IAAA;AAAAC,aAAAX,MAAA,MAEhCH,MAAMe,QAAQ;AAAA,WAAAZ;EAAA,GAAA;AAGlB;AAcO,SAASa,cACfC,gBACAC,cAMC;AAGD,QAAMC,YACLnB,WACI;AACJ,UAAMoB,SAASzB,WAAWuB,gBAAgB,CAAC,GAAGlB,KAAK;AAEnD,UAAM,CAACqB,OAAOC,SAAS,IAAI1B,WAAWwB,QAAe,CACpD,WACA,UACA,eACA,UACA,QACA,OAAO,CACP;AAED,UAAMG,OAAO7B,YAAW,MAAM;AAC7B,YAAM8B,WAAW1B,cAAc;QAC9BmB;QACAQ,MAAM;QACNzB,OAAO;UACN0B,SAASL,MAAMK;UACf,GAAIL,MAAMM,UAAU;YAAEA,QAAQN,MAAMM;UAAO;UAC3C,GAAIN,MAAMO,eAAe;YACxBA,aAAaP,MAAMO;UACpB;QACD;MACD,CAAC;AACD,YAAMC,MAAM,IAAIC,IAAIN,UAAUO,OAAOC,SAASC,MAAM;AACpD,UAAIZ,MAAMa,WAAWC,OAAWN,KAAIK,SAASb,MAAMa;AACnD,UAAIb,MAAMe,SAASD,OAAWN,KAAIO,OAAOf,MAAMe;AAC/C,aAAOP,IAAIN;IACZ,CAAC;AAED,WAAAc,mBAAQtC,WAASO,cAAKgB,WAAS;MAAA,IAAEC,OAAI;AAAA,eAAEA,KAAK;MAAC;MAAA,IAAEe,QAAK;AAAA,eAAEjB,MAAMiB;MAAK;IAAA,CAAA,CAAA;EAClE;AAEA,SAAOnB;AACR;",
|
|
6
|
+
"names": ["createMemo", "batch", "createEffect", "createMemo", "createRenderEffect", "createSignal", "Show", "Dynamic", "__applyScrollState", "addLocationListener", "addRouteChangeListener", "__vormaClientGlobal", "ctx", "getLocation", "getRouterData", "latestEvent", "setLatestEvent", "loadersData", "setLoadersData", "get", "clientLoadersData", "setClientLoadersData", "routerData", "setRouterData", "outermostErrorIdx", "setOutermostErrorIdx", "outermostError", "setOutermostError", "activeComponents", "setActiveComponents", "activeErrorBoundary", "setActiveErrorBoundary", "importURLs", "setImportURLs", "exportKeys", "setExportKeys", "isInited", "initUIListeners", "addRouteChangeListener", "e", "batch", "setLatestEvent", "setLoadersData", "ctx", "get", "setClientLoadersData", "setRouterData", "getRouterData", "setOutermostErrorIdx", "setOutermostError", "setActiveComponents", "setActiveErrorBoundary", "setImportURLs", "setExportKeys", "addLocationListener", "setLocation", "getLocation", "location", "createSignal", "VormaRootOutlet", "props", "idx", "initUIListeners", "batch", "setLoadersData", "ctx", "get", "setClientLoadersData", "setRouterData", "getRouterData", "setOutermostErrorIdx", "setOutermostError", "setActiveComponents", "setActiveErrorBoundary", "setImportURLs", "setExportKeys", "currentImportURL", "setCurrentImportURL", "createSignal", "importURLs", "currentExportKey", "setCurrentExportKey", "exportKeys", "createEffect", "e", "latestEvent", "newCurrentImportURL", "newCurrentExportKey", "createRenderEffect", "window", "requestAnimationFrame", "__applyScrollState", "detail", "__scrollState", "isErrorIdxMemo", "createMemo", "outermostErrorIdx", "currentCompMemo", "activeComponents", "shouldFallbackOutletMemo", "loadersData", "length", "errorCompMemo", "activeErrorBoundary", "remountKeyNext", "Outlet", "localProps", "_$createComponent", "Show", "when", "keyed", "children", "_$mergeProps", "Dynamic", "component", "fallback", "outermostError", "error", "createMemo", "props", "createMemo", "mergeProps", "splitProps", "__makeFinalLinkProps", "__resolvePath", "VormaLink", "props", "finalLinkProps", "rest", "_el$", "_tmpl$", "_$spread", "_$mergeProps", "dataExternal", "onPointerEnter", "onFocus", "onPointerLeave", "onBlur", "onTouchCancel", "onClick", "_$insert", "children", "makeTypedLink", "vormaAppConfig", "defaultProps", "TypedLink", "merged", "local", "linkProps", "href", "basePath", "type", "pattern", "params", "splatValues", "url", "URL", "window", "location", "origin", "search", "undefined", "hash", "_$createComponent", "state"]
|
|
7
|
+
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { type Accessor } from "solid-js";
|
|
2
|
+
import type { JSX } from "solid-js/jsx-runtime";
|
|
3
|
+
import { type ClientLoaderAwaitedServerData, type ParamsForPattern, type UseRouterDataFunction, type VormaAppBase, type VormaLoaderOutput, type VormaLoaderPattern, type VormaRouteGeneric, type VormaRoutePropsGeneric } from "vorma/client";
|
|
4
|
+
export type VormaRouteProps<App extends VormaAppBase = any, Pattern extends VormaLoaderPattern<App> = string> = VormaRoutePropsGeneric<JSX.Element, App, Pattern>;
|
|
5
|
+
export type VormaRoute<App extends VormaAppBase = any, Pattern extends VormaLoaderPattern<App> = string> = VormaRouteGeneric<JSX.Element, App, Pattern>;
|
|
6
|
+
export declare function makeTypedUseRouterData<App extends VormaAppBase>(): UseRouterDataFunction<App, true>;
|
|
7
|
+
export declare function makeTypedUseLoaderData<App extends VormaAppBase>(): <Pattern extends VormaLoaderPattern<App>>(props: VormaRouteProps<App, Pattern>) => Accessor<VormaLoaderOutput<App, Pattern>>;
|
|
8
|
+
export declare function makeTypedUsePatternLoaderData<App extends VormaAppBase>(): <Pattern extends VormaLoaderPattern<App>>(pattern: Pattern) => Accessor<VormaLoaderOutput<App, Pattern> | undefined>;
|
|
9
|
+
export declare function makeTypedAddClientLoader<App extends VormaAppBase>(): <Pattern extends VormaLoaderPattern<App>, LoaderData extends VormaLoaderOutput<App, Pattern>, T = any>(props: {
|
|
10
|
+
pattern: Pattern;
|
|
11
|
+
clientLoader: (props: {
|
|
12
|
+
params: Record<ParamsForPattern<App, Pattern>, string>;
|
|
13
|
+
splatValues: string[];
|
|
14
|
+
serverDataPromise: Promise<ClientLoaderAwaitedServerData<App["rootData"], LoaderData>>;
|
|
15
|
+
signal: AbortSignal;
|
|
16
|
+
}) => Promise<T>;
|
|
17
|
+
reRunOnModuleChange?: ImportMeta;
|
|
18
|
+
}) => {
|
|
19
|
+
(props: VormaRouteProps<App, Pattern>): Accessor<Awaited<T>>;
|
|
20
|
+
(): Accessor<Awaited<T> | undefined>;
|
|
21
|
+
};
|
|
22
|
+
//# sourceMappingURL=helpers.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"helpers.d.ts","sourceRoot":"","sources":["../../../../../../internal/framework/_typescript/solid/src/helpers.ts"],"names":[],"mappings":"AAEA,OAAO,EAAc,KAAK,QAAQ,EAAE,MAAM,UAAU,CAAC;AACrD,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,sBAAsB,CAAC;AAChD,OAAO,EAIN,KAAK,6BAA6B,EAClC,KAAK,gBAAgB,EACrB,KAAK,qBAAqB,EAC1B,KAAK,YAAY,EACjB,KAAK,iBAAiB,EACtB,KAAK,kBAAkB,EACvB,KAAK,iBAAiB,EACtB,KAAK,sBAAsB,EAC3B,MAAM,cAAc,CAAC;AAGtB,MAAM,MAAM,eAAe,CAC1B,GAAG,SAAS,YAAY,GAAG,GAAG,EAC9B,OAAO,SAAS,kBAAkB,CAAC,GAAG,CAAC,GAAG,MAAM,IAC7C,sBAAsB,CAAC,GAAG,CAAC,OAAO,EAAE,GAAG,EAAE,OAAO,CAAC,CAAC;AAEtD,MAAM,MAAM,UAAU,CACrB,GAAG,SAAS,YAAY,GAAG,GAAG,EAC9B,OAAO,SAAS,kBAAkB,CAAC,GAAG,CAAC,GAAG,MAAM,IAC7C,iBAAiB,CAAC,GAAG,CAAC,OAAO,EAAE,GAAG,EAAE,OAAO,CAAC,CAAC;AAEjD,wBAAgB,sBAAsB,CAAC,GAAG,SAAS,YAAY,KACjC,qBAAqB,CAAC,GAAG,EAAE,IAAI,CAAC,CAC7D;AAED,wBAAgB,sBAAsB,CAAC,GAAG,SAAS,YAAY,MAChC,OAAO,SAAS,kBAAkB,CAAC,GAAG,CAAC,EACpE,OAAO,eAAe,CAAC,GAAG,EAAE,OAAO,CAAC,KAClC,QAAQ,CAAC,iBAAiB,CAAC,GAAG,EAAE,OAAO,CAAC,CAAC,CAK5C;AAED,wBAAgB,6BAA6B,CAAC,GAAG,SAAS,YAAY,MAEpE,OAAO,SAAS,kBAAkB,CAAC,GAAG,CAAC,EACtC,SAAS,OAAO,KAAG,QAAQ,CAAC,iBAAiB,CAAC,GAAG,EAAE,OAAO,CAAC,GAAG,SAAS,CAAC,CAc1E;AAED,wBAAgB,wBAAwB,CAAC,GAAG,SAAS,YAAY,MAG/D,OAAO,SAAS,kBAAkB,CAAC,GAAG,CAAC,EACvC,UAAU,SAAS,iBAAiB,CAAC,GAAG,EAAE,OAAO,CAAC,EAClD,CAAC,GAAG,GAAG,EACN,OAAO;IACR,OAAO,EAAE,OAAO,CAAC;IACjB,YAAY,EAAE,CAAC,KAAK,EAAE;QACrB,MAAM,EAAE,MAAM,CAAC,gBAAgB,CAAC,GAAG,EAAE,OAAO,CAAC,EAAE,MAAM,CAAC,CAAC;QACvD,WAAW,EAAE,MAAM,EAAE,CAAC;QACtB,iBAAiB,EAAE,OAAO,CACzB,6BAA6B,CAAC,GAAG,CAAC,UAAU,CAAC,EAAE,UAAU,CAAC,CAC1D,CAAC;QACF,MAAM,EAAE,WAAW,CAAC;KACpB,KAAK,OAAO,CAAC,CAAC,CAAC,CAAC;IACjB,mBAAmB,CAAC,EAAE,UAAU,CAAC;CACjC,KA6B8B;IAC7B,CAAC,KAAK,EAAE,eAAe,CAAC,GAAG,EAAE,OAAO,CAAC,GAAG,QAAQ,YAAK,CAAC;IACtD,IAAI,QAAQ,CAAC,aAAM,SAAS,CAAC,CAAC;CAC9B,CAEF"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { type JSX } from "solid-js";
|
|
2
|
+
import type { ExtractApp, PermissivePatternBasedProps, VormaAppBase, VormaLoaderPattern } from "vorma/client";
|
|
3
|
+
import { type VormaAppConfig, type VormaLinkPropsBase } from "vorma/client";
|
|
4
|
+
export declare function VormaLink(props: JSX.AnchorHTMLAttributes<HTMLAnchorElement> & VormaLinkPropsBase<JSX.CustomEventHandlersCamelCase<HTMLAnchorElement>["onClick"]>): JSX.Element;
|
|
5
|
+
type TypedVormaLinkProps<App extends VormaAppBase, Pattern extends VormaLoaderPattern<App> = VormaLoaderPattern<App>> = Omit<JSX.AnchorHTMLAttributes<HTMLAnchorElement>, "href" | "pattern"> & VormaLinkPropsBase<JSX.CustomEventHandlersCamelCase<HTMLAnchorElement>["onClick"]> & PermissivePatternBasedProps<App, Pattern> & {
|
|
6
|
+
search?: string;
|
|
7
|
+
hash?: string;
|
|
8
|
+
};
|
|
9
|
+
export declare function makeTypedLink<C extends VormaAppConfig>(vormaAppConfig: C, defaultProps?: Partial<Omit<TypedVormaLinkProps<ExtractApp<C>>, "pattern" | "params" | "splatValues">>): <Pattern extends VormaLoaderPattern<ExtractApp<C>>>(props: TypedVormaLinkProps<ExtractApp<C>, Pattern>) => JSX.Element;
|
|
10
|
+
export {};
|
|
11
|
+
//# sourceMappingURL=link.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"link.d.ts","sourceRoot":"","sources":["../../../../../../internal/framework/_typescript/solid/src/link.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAsC,KAAK,GAAG,EAAE,MAAM,UAAU,CAAC;AACxE,OAAO,KAAK,EACX,UAAU,EACV,2BAA2B,EAC3B,YAAY,EACZ,kBAAkB,EAClB,MAAM,cAAc,CAAC;AACtB,OAAO,EAGN,KAAK,cAAc,EACnB,KAAK,kBAAkB,EACvB,MAAM,cAAc,CAAC;AAEtB,wBAAgB,SAAS,CACxB,KAAK,EAAE,GAAG,CAAC,oBAAoB,CAAC,iBAAiB,CAAC,GACjD,kBAAkB,CACjB,GAAG,CAAC,4BAA4B,CAAC,iBAAiB,CAAC,CAAC,SAAS,CAAC,CAC9D,eAwBF;AAED,KAAK,mBAAmB,CACvB,GAAG,SAAS,YAAY,EACxB,OAAO,SAAS,kBAAkB,CAAC,GAAG,CAAC,GAAG,kBAAkB,CAAC,GAAG,CAAC,IAC9D,IAAI,CAAC,GAAG,CAAC,oBAAoB,CAAC,iBAAiB,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC,GACxE,kBAAkB,CACjB,GAAG,CAAC,4BAA4B,CAAC,iBAAiB,CAAC,CAAC,SAAS,CAAC,CAC9D,GACD,2BAA2B,CAAC,GAAG,EAAE,OAAO,CAAC,GAAG;IAC3C,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,IAAI,CAAC,EAAE,MAAM,CAAC;CACd,CAAC;AAEH,wBAAgB,aAAa,CAAC,CAAC,SAAS,cAAc,EACrD,cAAc,EAAE,CAAC,EACjB,YAAY,CAAC,EAAE,OAAO,CACrB,IAAI,CACH,mBAAmB,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC,EAClC,SAAS,GAAG,QAAQ,GAAG,aAAa,CACpC,CACD,IAIkB,OAAO,SAAS,kBAAkB,eAAK,SAClD,mBAAmB,gBAAM,OAAO,CAAC,iBAmCzC"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { type JSX } from "solid-js";
|
|
2
|
+
declare const loadersData: import("solid-js").Accessor<any[]>;
|
|
3
|
+
declare const clientLoadersData: import("solid-js").Accessor<any[]>;
|
|
4
|
+
declare const routerData: import("solid-js").Accessor<{
|
|
5
|
+
buildID: string;
|
|
6
|
+
matchedPatterns: string[];
|
|
7
|
+
splatValues: string[];
|
|
8
|
+
params: Record<string, string>;
|
|
9
|
+
rootData: any;
|
|
10
|
+
}>;
|
|
11
|
+
export { clientLoadersData, loadersData, routerData };
|
|
12
|
+
declare const location: import("solid-js").Accessor<{
|
|
13
|
+
pathname: string;
|
|
14
|
+
search: string;
|
|
15
|
+
hash: string;
|
|
16
|
+
state: unknown;
|
|
17
|
+
}>;
|
|
18
|
+
export { location };
|
|
19
|
+
export declare function VormaRootOutlet(props: {
|
|
20
|
+
idx?: number;
|
|
21
|
+
}): JSX.Element;
|
|
22
|
+
//# sourceMappingURL=solid.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"solid.d.ts","sourceRoot":"","sources":["../../../../../../internal/framework/_typescript/solid/src/solid.tsx"],"names":[],"mappings":"AAAA,OAAO,EAMN,KAAK,GAAG,EAER,MAAM,UAAU,CAAC;AAmBlB,QAAA,MAAO,WAAW,oCAAwD,CAAC;AAC3E,QAAA,MAAO,iBAAiB,oCAEvB,CAAC;AACF,QAAA,MAAO,UAAU;;;;;;EAAgD,CAAC;AAgBlE,OAAO,EAAE,iBAAiB,EAAE,WAAW,EAAE,UAAU,EAAE,CAAC;AA4BtD,QAAA,MAAO,QAAQ;;;;;EAA4C,CAAC;AAE5D,OAAO,EAAE,QAAQ,EAAE,CAAC;AAMpB,wBAAgB,eAAe,CAAC,KAAK,EAAE;IAAE,GAAG,CAAC,EAAE,MAAM,CAAA;CAAE,GAAG,GAAG,CAAC,OAAO,CAwHpE"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
type VormaVitePluginConfig = {
|
|
2
|
+
rollupInput: ReadonlyArray<string>;
|
|
3
|
+
publicPathPrefix: string;
|
|
4
|
+
staticPublicAssetMap: Record<string, string>;
|
|
5
|
+
buildtimePublicURLFuncName: string;
|
|
6
|
+
ignoredPatterns: ReadonlyArray<string>;
|
|
7
|
+
dedupeList: ReadonlyArray<string>;
|
|
8
|
+
};
|
|
9
|
+
export default function vormaVitePlugin(config: VormaVitePluginConfig): any;
|
|
10
|
+
export {};
|
|
11
|
+
//# sourceMappingURL=vite.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"vite.d.ts","sourceRoot":"","sources":["../../../../../internal/framework/_typescript/vite/vite.ts"],"names":[],"mappings":"AAAA,KAAK,qBAAqB,GAAG;IAC5B,WAAW,EAAE,aAAa,CAAC,MAAM,CAAC,CAAC;IACnC,gBAAgB,EAAE,MAAM,CAAC;IACzB,oBAAoB,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAC7C,0BAA0B,EAAE,MAAM,CAAC;IACnC,eAAe,EAAE,aAAa,CAAC,MAAM,CAAC,CAAC;IACvC,UAAU,EAAE,aAAa,CAAC,MAAM,CAAC,CAAC;CAClC,CAAC;AAEF,MAAM,CAAC,OAAO,UAAU,eAAe,CAAC,MAAM,EAAE,qBAAqB,GAAG,GAAG,CAmF1E"}
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
// internal/framework/_typescript/vite/vite.ts
|
|
2
|
+
function vormaVitePlugin(config) {
|
|
3
|
+
return {
|
|
4
|
+
name: "vorma-vite-plugin",
|
|
5
|
+
config(c, { command }) {
|
|
6
|
+
const mp = c.build?.modulePreload;
|
|
7
|
+
const roi = c.build?.rollupOptions?.input;
|
|
8
|
+
const ign = c.server?.watch?.ignored;
|
|
9
|
+
const dedupe = c.resolve?.dedupe;
|
|
10
|
+
const isDev = command === "serve";
|
|
11
|
+
return {
|
|
12
|
+
base: isDev ? "/" : config.publicPathPrefix,
|
|
13
|
+
build: {
|
|
14
|
+
target: "es2022",
|
|
15
|
+
emptyOutDir: false,
|
|
16
|
+
modulePreload: {
|
|
17
|
+
polyfill: false,
|
|
18
|
+
...typeof mp === "object" ? mp : {}
|
|
19
|
+
},
|
|
20
|
+
rollupOptions: {
|
|
21
|
+
...c.build?.rollupOptions,
|
|
22
|
+
input: [
|
|
23
|
+
...config.rollupInput,
|
|
24
|
+
...Array.isArray(roi) ? roi : []
|
|
25
|
+
],
|
|
26
|
+
preserveEntrySignatures: "exports-only",
|
|
27
|
+
output: {
|
|
28
|
+
assetFileNames: "vorma_out_vite_[name]-[hash][extname]",
|
|
29
|
+
chunkFileNames: "vorma_out_vite_[name]-[hash].js",
|
|
30
|
+
entryFileNames: "vorma_out_vite_[name]-[hash].js"
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
},
|
|
34
|
+
server: {
|
|
35
|
+
headers: {
|
|
36
|
+
...c.server?.headers,
|
|
37
|
+
// ensure versions of dynamic imports without the latest
|
|
38
|
+
// hmr updates are not cached by the browser during dev
|
|
39
|
+
"cache-control": "no-store"
|
|
40
|
+
},
|
|
41
|
+
watch: {
|
|
42
|
+
...c.server?.watch,
|
|
43
|
+
ignored: [
|
|
44
|
+
...Array.isArray(ign) ? ign : [],
|
|
45
|
+
...config.ignoredPatterns
|
|
46
|
+
]
|
|
47
|
+
}
|
|
48
|
+
},
|
|
49
|
+
resolve: {
|
|
50
|
+
dedupe: [
|
|
51
|
+
...Array.isArray(dedupe) ? dedupe : [],
|
|
52
|
+
...config.dedupeList
|
|
53
|
+
]
|
|
54
|
+
}
|
|
55
|
+
};
|
|
56
|
+
},
|
|
57
|
+
transform(code, id) {
|
|
58
|
+
const isNodeModules = /node_modules/.test(id);
|
|
59
|
+
if (isNodeModules) return null;
|
|
60
|
+
const regex = new RegExp(
|
|
61
|
+
`${config.buildtimePublicURLFuncName}\\s*\\(\\s*(["'\`])(.*?)\\1\\s*\\)`,
|
|
62
|
+
"g"
|
|
63
|
+
);
|
|
64
|
+
const needsReplacement = regex.test(code);
|
|
65
|
+
if (!needsReplacement) return null;
|
|
66
|
+
const replacedCode = code.replace(
|
|
67
|
+
regex,
|
|
68
|
+
(_, __, assetPath) => {
|
|
69
|
+
const hashed = config.staticPublicAssetMap[assetPath];
|
|
70
|
+
if (!hashed) return `"${assetPath}"`;
|
|
71
|
+
return `"${config.publicPathPrefix}${hashed}"`;
|
|
72
|
+
}
|
|
73
|
+
);
|
|
74
|
+
if (replacedCode === code) return null;
|
|
75
|
+
return replacedCode;
|
|
76
|
+
}
|
|
77
|
+
};
|
|
78
|
+
}
|
|
79
|
+
export {
|
|
80
|
+
vormaVitePlugin as default
|
|
81
|
+
};
|
|
82
|
+
//# sourceMappingURL=vite.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../../../internal/framework/_typescript/vite/vite.ts"],
|
|
4
|
+
"sourcesContent": ["type VormaVitePluginConfig = {\n\trollupInput: ReadonlyArray<string>;\n\tpublicPathPrefix: string;\n\tstaticPublicAssetMap: Record<string, string>;\n\tbuildtimePublicURLFuncName: string;\n\tignoredPatterns: ReadonlyArray<string>;\n\tdedupeList: ReadonlyArray<string>;\n};\n\nexport default function vormaVitePlugin(config: VormaVitePluginConfig): any {\n\treturn {\n\t\tname: \"vorma-vite-plugin\",\n\t\tconfig(c: any, { command }: any) {\n\t\t\tconst mp = c.build?.modulePreload;\n\t\t\tconst roi = c.build?.rollupOptions?.input;\n\t\t\tconst ign = c.server?.watch?.ignored;\n\t\t\tconst dedupe = c.resolve?.dedupe;\n\n\t\t\tconst isDev = command === \"serve\";\n\n\t\t\treturn {\n\t\t\t\tbase: isDev ? \"/\" : config.publicPathPrefix,\n\t\t\t\tbuild: {\n\t\t\t\t\ttarget: \"es2022\",\n\t\t\t\t\temptyOutDir: false,\n\t\t\t\t\tmodulePreload: {\n\t\t\t\t\t\tpolyfill: false,\n\t\t\t\t\t\t...(typeof mp === \"object\" ? mp : {}),\n\t\t\t\t\t},\n\t\t\t\t\trollupOptions: {\n\t\t\t\t\t\t...c.build?.rollupOptions,\n\t\t\t\t\t\tinput: [\n\t\t\t\t\t\t\t...config.rollupInput,\n\t\t\t\t\t\t\t...(Array.isArray(roi) ? roi : []),\n\t\t\t\t\t\t],\n\t\t\t\t\t\tpreserveEntrySignatures: \"exports-only\",\n\t\t\t\t\t\toutput: {\n\t\t\t\t\t\t\tassetFileNames:\n\t\t\t\t\t\t\t\t\"vorma_out_vite_[name]-[hash][extname]\",\n\t\t\t\t\t\t\tchunkFileNames: \"vorma_out_vite_[name]-[hash].js\",\n\t\t\t\t\t\t\tentryFileNames: \"vorma_out_vite_[name]-[hash].js\",\n\t\t\t\t\t\t},\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\tserver: {\n\t\t\t\t\theaders: {\n\t\t\t\t\t\t...c.server?.headers,\n\t\t\t\t\t\t// ensure versions of dynamic imports without the latest\n\t\t\t\t\t\t// hmr updates are not cached by the browser during dev\n\t\t\t\t\t\t\"cache-control\": \"no-store\",\n\t\t\t\t\t},\n\t\t\t\t\twatch: {\n\t\t\t\t\t\t...c.server?.watch,\n\t\t\t\t\t\tignored: [\n\t\t\t\t\t\t\t...(Array.isArray(ign) ? ign : []),\n\t\t\t\t\t\t\t...config.ignoredPatterns,\n\t\t\t\t\t\t],\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\tresolve: {\n\t\t\t\t\tdedupe: [\n\t\t\t\t\t\t...(Array.isArray(dedupe) ? dedupe : []),\n\t\t\t\t\t\t...config.dedupeList,\n\t\t\t\t\t],\n\t\t\t\t},\n\t\t\t};\n\t\t},\n\t\ttransform(code: any, id: any) {\n\t\t\tconst isNodeModules = /node_modules/.test(id);\n\t\t\tif (isNodeModules) return null;\n\n\t\t\tconst regex = new RegExp(\n\t\t\t\t`${config.buildtimePublicURLFuncName}\\\\s*\\\\(\\\\s*([\"'\\`])(.*?)\\\\1\\\\s*\\\\)`,\n\t\t\t\t\"g\",\n\t\t\t);\n\n\t\t\tconst needsReplacement = regex.test(code);\n\t\t\tif (!needsReplacement) return null;\n\n\t\t\tconst replacedCode = code.replace(\n\t\t\t\tregex,\n\t\t\t\t(_: any, __: any, assetPath: any) => {\n\t\t\t\t\tconst hashed = config.staticPublicAssetMap[assetPath];\n\t\t\t\t\tif (!hashed) return `\"${assetPath}\"`;\n\t\t\t\t\treturn `\"${config.publicPathPrefix}${hashed}\"`;\n\t\t\t\t},\n\t\t\t);\n\n\t\t\tif (replacedCode === code) return null;\n\t\t\treturn replacedCode;\n\t\t},\n\t};\n}\n"],
|
|
5
|
+
"mappings": ";AASe,SAAR,gBAAiC,QAAoC;AAC3E,SAAO;AAAA,IACN,MAAM;AAAA,IACN,OAAO,GAAQ,EAAE,QAAQ,GAAQ;AAChC,YAAM,KAAK,EAAE,OAAO;AACpB,YAAM,MAAM,EAAE,OAAO,eAAe;AACpC,YAAM,MAAM,EAAE,QAAQ,OAAO;AAC7B,YAAM,SAAS,EAAE,SAAS;AAE1B,YAAM,QAAQ,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