@resistdesign/voltra 3.0.0-alpha.35 → 3.0.0-alpha.36
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/api/index.js +2 -2
- package/app/index.js +4 -4
- package/app/utils/Route.d.ts +16 -1
- package/app/utils/RouteHistory.d.ts +1 -0
- package/build/index.js +1 -1
- package/{chunk-WTD5BBJP.js → chunk-C3LXDJM5.js} +1 -1
- package/{chunk-BKRJZXWX.js → chunk-TNQLXU6L.js} +1 -1
- package/{chunk-GYWRAW3Y.js → chunk-WNFRDIBW.js} +56 -13
- package/{chunk-X3NHBZUT.js → chunk-Z7T6VEWO.js} +64 -22
- package/common/Routing.d.ts +14 -0
- package/common/index.js +2 -2
- package/native/index.js +6 -5
- package/package.json +1 -1
- package/web/index.js +4 -4
package/api/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ITEM_RELATIONSHIP_DAC_RESOURCE_NAME, ComparisonOperators } from '../chunk-7AMEFPPP.js';
|
|
2
|
-
import { getNoErrorDescriptor, getErrorDescriptor, ERROR_MESSAGE_CONSTANTS, validateTypeOperationAllowed, getValidityValue, validateTypeInfoValue, validateTypeInfoFieldValue } from '../chunk-
|
|
3
|
-
import { mergeStringPaths, getPathString, getPathArray } from '../chunk-
|
|
2
|
+
import { getNoErrorDescriptor, getErrorDescriptor, ERROR_MESSAGE_CONSTANTS, validateTypeOperationAllowed, getValidityValue, validateTypeInfoValue, validateTypeInfoFieldValue } from '../chunk-C3LXDJM5.js';
|
|
3
|
+
import { mergeStringPaths, getPathString, getPathArray } from '../chunk-WNFRDIBW.js';
|
|
4
4
|
import '../chunk-I2KLQ2HA.js';
|
|
5
5
|
import { QueryCommand, GetItemCommand, BatchGetItemCommand, BatchWriteItemCommand, DynamoDBClient, PutItemCommand, UpdateItemCommand, DeleteItemCommand, ScanCommand } from '@aws-sdk/client-dynamodb';
|
|
6
6
|
import { marshall, unmarshall } from '@aws-sdk/util-dynamodb';
|
package/app/index.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
export { createEasyLayout, getEasyLayoutTemplateDetails, getPascalCaseAreaName } from '../chunk-
|
|
1
|
+
export { createEasyLayout, getEasyLayoutTemplateDetails, getPascalCaseAreaName } from '../chunk-TNQLXU6L.js';
|
|
2
2
|
export { computeTrackPixels } from '../chunk-TJFTWPXQ.js';
|
|
3
|
-
export { AutoForm, AutoFormView, Route, RouteContext, RouteContextConsumer, RouteContextProvider, RouteProvider, buildHistoryPath, buildQueryString, buildRoutePath, canUseBrowserHistory, computeAreaBounds, createAutoField, createBrowserRouteAdapter, createFormRenderer, createHistoryBackHandler, createManualRouteAdapter, createMemoryHistory, createNativeRouteAdapter, createRouteAdapterFromHistory, createUniversalAdapter, defaultTranslateValidationErrorCode, getFieldKind, parseHistoryPath, parseTemplate, resolveSuite, useFormEngine, useRouteContext, validateAreas } from '../chunk-
|
|
3
|
+
export { AutoForm, AutoFormView, Route, RouteContext, RouteContextConsumer, RouteContextProvider, RouteProvider, buildHistoryPath, buildQueryString, buildRoutePath, canUseBrowserHistory, computeAreaBounds, createAutoField, createBrowserRouteAdapter, createFormRenderer, createHistoryBackHandler, createManualRouteAdapter, createMemoryHistory, createNativeRouteAdapter, createRouteAdapterFromHistory, createUniversalAdapter, defaultTranslateValidationErrorCode, getFieldKind, parseHistoryPath, parseTemplate, resolveSuite, useFormEngine, useRouteContext, validateAreas, wrapRouteAdapterWithPathResolver } from '../chunk-Z7T6VEWO.js';
|
|
4
4
|
import '../chunk-7AMEFPPP.js';
|
|
5
|
-
import '../chunk-
|
|
6
|
-
import { mergeStringPaths, PATH_DELIMITER } from '../chunk-
|
|
5
|
+
import '../chunk-C3LXDJM5.js';
|
|
6
|
+
import { mergeStringPaths, PATH_DELIMITER } from '../chunk-WNFRDIBW.js';
|
|
7
7
|
import '../chunk-I2KLQ2HA.js';
|
|
8
8
|
import { createContext, useContext, useRef, useMemo, useCallback, useState, useEffect } from 'react';
|
|
9
9
|
import { jsx } from 'react/jsx-runtime';
|
package/app/utils/Route.d.ts
CHANGED
|
@@ -14,7 +14,12 @@ export type RouteAdapter = {
|
|
|
14
14
|
getPath: () => string;
|
|
15
15
|
/** Subscribe to path changes. */
|
|
16
16
|
subscribe: (listener: (path: string) => void) => () => void;
|
|
17
|
-
/**
|
|
17
|
+
/**
|
|
18
|
+
* Optional navigation helper for adapters that can push state.
|
|
19
|
+
*
|
|
20
|
+
* `push`/`replace` paths are normalized through shared routing utils:
|
|
21
|
+
* absolute (`/x`), relative (`x`, `./x`, `../x`), and empty (`""` => `/`).
|
|
22
|
+
*/
|
|
18
23
|
push?: (path: string, title?: string) => void;
|
|
19
24
|
/** Optional navigation helper for adapters that can replace state. */
|
|
20
25
|
replace?: (path: string, title?: string) => void;
|
|
@@ -105,6 +110,16 @@ export declare const RouteContextProvider: import("react").Provider<RouteContext
|
|
|
105
110
|
* @returns The current route context.
|
|
106
111
|
*/
|
|
107
112
|
export declare const useRouteContext: () => RouteContextType;
|
|
113
|
+
/**
|
|
114
|
+
* Wrap a RouteAdapter so `push` and `replace` resolve relative paths.
|
|
115
|
+
*
|
|
116
|
+
* This preserves existing adapter behavior for subscriptions/back navigation,
|
|
117
|
+
* while normalizing path syntax consistently across web/native/app wrappers.
|
|
118
|
+
*
|
|
119
|
+
* @param adapter - RouteAdapter to normalize.
|
|
120
|
+
* @returns Adapter with relative-aware `push` and `replace`.
|
|
121
|
+
*/
|
|
122
|
+
export declare const wrapRouteAdapterWithPathResolver: (adapter: RouteAdapter) => RouteAdapter;
|
|
108
123
|
/**
|
|
109
124
|
* RouteProvider props.
|
|
110
125
|
*/
|
|
@@ -13,6 +13,7 @@ import type { RouteAdapter } from "./Route";
|
|
|
13
13
|
*
|
|
14
14
|
* Adapter navigation methods call history with `replaceSearch: true` so a
|
|
15
15
|
* path-only navigation does not accidentally retain a previous query string.
|
|
16
|
+
* Relative navigation input is resolved against the current history path.
|
|
16
17
|
*
|
|
17
18
|
* Example:
|
|
18
19
|
* ```ts
|
package/build/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { getPotentialJSONValue, getPathArray } from '../chunk-
|
|
1
|
+
import { getPotentialJSONValue, getPathArray } from '../chunk-WNFRDIBW.js';
|
|
2
2
|
import '../chunk-I2KLQ2HA.js';
|
|
3
3
|
import { SyntaxKind, isLiteralTypeNode, isStringLiteral, isNumericLiteral, createSourceFile, ScriptTarget } from 'typescript';
|
|
4
4
|
|
|
@@ -33,22 +33,65 @@ var mergeStringPaths = (path1, path2, delimiter = PATH_DELIMITER, filterEmptyOut
|
|
|
33
33
|
useJson,
|
|
34
34
|
uriEncodeParts
|
|
35
35
|
);
|
|
36
|
-
var
|
|
37
|
-
|
|
38
|
-
let
|
|
39
|
-
|
|
40
|
-
|
|
36
|
+
var splitRoutePathParts = (rawPath) => {
|
|
37
|
+
let path = rawPath;
|
|
38
|
+
let hash = "";
|
|
39
|
+
let search = "";
|
|
40
|
+
const hashIndex = path.indexOf("#");
|
|
41
|
+
if (hashIndex >= 0) {
|
|
42
|
+
hash = path.slice(hashIndex);
|
|
43
|
+
path = path.slice(0, hashIndex);
|
|
41
44
|
}
|
|
42
|
-
|
|
45
|
+
const searchIndex = path.indexOf("?");
|
|
46
|
+
if (searchIndex >= 0) {
|
|
47
|
+
search = path.slice(searchIndex);
|
|
48
|
+
path = path.slice(0, searchIndex);
|
|
49
|
+
}
|
|
50
|
+
return {
|
|
51
|
+
path,
|
|
52
|
+
search,
|
|
53
|
+
hash
|
|
54
|
+
};
|
|
55
|
+
};
|
|
56
|
+
var resolveRouteAdapterPath = (currentPath, nextPath) => {
|
|
57
|
+
const rawNextPath = String(nextPath ?? "").trim();
|
|
58
|
+
if (rawNextPath === "") {
|
|
59
|
+
return "/";
|
|
60
|
+
}
|
|
61
|
+
const { path: rawCurrentBase } = splitRoutePathParts(
|
|
62
|
+
String(currentPath ?? "").trim()
|
|
63
|
+
);
|
|
64
|
+
const { path: rawRelativePath, search, hash } = splitRoutePathParts(rawNextPath);
|
|
65
|
+
const isAbsoluteTarget = rawRelativePath.startsWith(PATH_DELIMITER);
|
|
66
|
+
const currentSegments = getPathArray(
|
|
67
|
+
rawCurrentBase || PATH_DELIMITER,
|
|
68
|
+
PATH_DELIMITER,
|
|
69
|
+
true,
|
|
70
|
+
true,
|
|
71
|
+
false,
|
|
72
|
+
false
|
|
73
|
+
);
|
|
74
|
+
const outputSegments = isAbsoluteTarget ? [] : [...currentSegments];
|
|
75
|
+
const relativeSegments = getPathArray(
|
|
76
|
+
rawRelativePath,
|
|
77
|
+
PATH_DELIMITER,
|
|
78
|
+
true,
|
|
79
|
+
true,
|
|
80
|
+
false,
|
|
81
|
+
false
|
|
82
|
+
);
|
|
83
|
+
relativeSegments.forEach((segment) => {
|
|
84
|
+
if (segment === "." || segment === "") {
|
|
85
|
+
return;
|
|
86
|
+
}
|
|
43
87
|
if (segment === "..") {
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
}
|
|
47
|
-
} else if (segment !== ".") {
|
|
48
|
-
currentSegments.push(segment);
|
|
88
|
+
outputSegments.pop();
|
|
89
|
+
return;
|
|
49
90
|
}
|
|
91
|
+
outputSegments.push(segment);
|
|
50
92
|
});
|
|
51
|
-
|
|
93
|
+
const resolvedPath = outputSegments.length > 0 ? `/${outputSegments.join(PATH_DELIMITER)}` : PATH_DELIMITER;
|
|
94
|
+
return `${resolvedPath}${search}${hash}`;
|
|
52
95
|
};
|
|
53
96
|
var getParamsAndTestPath = (path, testPath, exact = false) => {
|
|
54
97
|
const pathList = getPathArray(path);
|
|
@@ -75,4 +118,4 @@ var getParamsAndTestPath = (path, testPath, exact = false) => {
|
|
|
75
118
|
}
|
|
76
119
|
};
|
|
77
120
|
|
|
78
|
-
export { PATH_DELIMITER, getParamsAndTestPath, getPathArray, getPathString, getPotentialJSONValue, mergeStringPaths,
|
|
121
|
+
export { PATH_DELIMITER, getParamsAndTestPath, getPathArray, getPathString, getPotentialJSONValue, mergeStringPaths, resolveRouteAdapterPath };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { getErrorDescriptor, getNoErrorDescriptor, validateTypeInfoDataItem, getArrayItemErrorMap, getErrorDescriptors, ERROR_MESSAGE_CONSTANTS } from './chunk-
|
|
2
|
-
import { getPathString, mergeStringPaths, getParamsAndTestPath
|
|
3
|
-
import { createContext, useContext, useState, useEffect,
|
|
1
|
+
import { getErrorDescriptor, getNoErrorDescriptor, validateTypeInfoDataItem, getArrayItemErrorMap, getErrorDescriptors, ERROR_MESSAGE_CONSTANTS } from './chunk-C3LXDJM5.js';
|
|
2
|
+
import { resolveRouteAdapterPath, getPathString, mergeStringPaths, getParamsAndTestPath } from './chunk-WNFRDIBW.js';
|
|
3
|
+
import { createContext, useContext, useMemo, useState, useEffect, useCallback, createElement, useRef } from 'react';
|
|
4
4
|
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
5
5
|
|
|
6
6
|
// src/app/utils/easy-layout/parseTemplate.ts
|
|
@@ -309,10 +309,14 @@ var createRouteAdapterFromHistory = (history) => {
|
|
|
309
309
|
});
|
|
310
310
|
},
|
|
311
311
|
push: (path) => {
|
|
312
|
-
history.push(path, {
|
|
312
|
+
history.push(resolveRouteAdapterPath(history.location.path, path), {
|
|
313
|
+
replaceSearch: true
|
|
314
|
+
});
|
|
313
315
|
},
|
|
314
316
|
replace: (path) => {
|
|
315
|
-
history.replace(path, {
|
|
317
|
+
history.replace(resolveRouteAdapterPath(history.location.path, path), {
|
|
318
|
+
replaceSearch: true
|
|
319
|
+
});
|
|
316
320
|
},
|
|
317
321
|
back: history.back,
|
|
318
322
|
canGoBack: () => history.index > 0
|
|
@@ -365,22 +369,30 @@ var createBrowserRouteAdapter = () => {
|
|
|
365
369
|
if (!WINDOW?.history) {
|
|
366
370
|
return;
|
|
367
371
|
}
|
|
368
|
-
const
|
|
372
|
+
const resolvedPath = resolveRouteAdapterPath(
|
|
373
|
+
WINDOW.location?.pathname ?? "",
|
|
374
|
+
path
|
|
375
|
+
);
|
|
376
|
+
const targetPath = parseHistoryPath(resolvedPath).path;
|
|
369
377
|
if (targetPath === (WINDOW.location?.pathname ?? "")) {
|
|
370
378
|
return;
|
|
371
379
|
}
|
|
372
|
-
WINDOW.history.pushState({}, title,
|
|
380
|
+
WINDOW.history.pushState({}, title, resolvedPath);
|
|
373
381
|
notify();
|
|
374
382
|
},
|
|
375
383
|
replace: (path, title = "") => {
|
|
376
384
|
if (!WINDOW?.history?.replaceState) {
|
|
377
385
|
return;
|
|
378
386
|
}
|
|
379
|
-
const
|
|
387
|
+
const resolvedPath = resolveRouteAdapterPath(
|
|
388
|
+
WINDOW.location?.pathname ?? "",
|
|
389
|
+
path
|
|
390
|
+
);
|
|
391
|
+
const targetPath = parseHistoryPath(resolvedPath).path;
|
|
380
392
|
if (targetPath === (WINDOW.location?.pathname ?? "")) {
|
|
381
393
|
return;
|
|
382
394
|
}
|
|
383
|
-
WINDOW.history.replaceState({}, title,
|
|
395
|
+
WINDOW.history.replaceState({}, title, resolvedPath);
|
|
384
396
|
notify();
|
|
385
397
|
},
|
|
386
398
|
back: () => WINDOW?.history?.back(),
|
|
@@ -434,16 +446,18 @@ var createNativeRouteAdapter = (initialPath = "/", ingress) => {
|
|
|
434
446
|
return {
|
|
435
447
|
...adapter,
|
|
436
448
|
push: (path, title) => {
|
|
437
|
-
|
|
449
|
+
const resolvedPath = resolveRouteAdapterPath(history.location.path, path);
|
|
450
|
+
if (parseHistoryPath(resolvedPath).path === history.location.path) {
|
|
438
451
|
return;
|
|
439
452
|
}
|
|
440
|
-
adapter.push?.(
|
|
453
|
+
adapter.push?.(resolvedPath, title);
|
|
441
454
|
},
|
|
442
455
|
replace: (path, title) => {
|
|
443
|
-
|
|
456
|
+
const resolvedPath = resolveRouteAdapterPath(history.location.path, path);
|
|
457
|
+
if (parseHistoryPath(resolvedPath).path === history.location.path) {
|
|
444
458
|
return;
|
|
445
459
|
}
|
|
446
|
-
adapter.replace?.(
|
|
460
|
+
adapter.replace?.(resolvedPath, title);
|
|
447
461
|
},
|
|
448
462
|
subscribe: (listener) => {
|
|
449
463
|
subscribers += 1;
|
|
@@ -490,8 +504,8 @@ var createManualRouteAdapter = (initialPath = "/") => {
|
|
|
490
504
|
listeners.delete(listener);
|
|
491
505
|
};
|
|
492
506
|
},
|
|
493
|
-
push: (path) => updatePath(path),
|
|
494
|
-
replace: (path) => updatePath(path)
|
|
507
|
+
push: (path) => updatePath(resolveRouteAdapterPath(currentPath, path)),
|
|
508
|
+
replace: (path) => updatePath(resolveRouteAdapterPath(currentPath, path))
|
|
495
509
|
};
|
|
496
510
|
return {
|
|
497
511
|
adapter,
|
|
@@ -543,6 +557,27 @@ var {
|
|
|
543
557
|
Consumer: RouteContextConsumer
|
|
544
558
|
} = RouteContext;
|
|
545
559
|
var useRouteContext = () => useContext(RouteContext);
|
|
560
|
+
var wrappedRouteAdapterCache = /* @__PURE__ */ new WeakMap();
|
|
561
|
+
var wrapRouteAdapterWithPathResolver = (adapter) => {
|
|
562
|
+
if (!adapter.push && !adapter.replace) {
|
|
563
|
+
return adapter;
|
|
564
|
+
}
|
|
565
|
+
const cachedAdapter = wrappedRouteAdapterCache.get(adapter);
|
|
566
|
+
if (cachedAdapter) {
|
|
567
|
+
return cachedAdapter;
|
|
568
|
+
}
|
|
569
|
+
const wrappedAdapter = {
|
|
570
|
+
...adapter,
|
|
571
|
+
push: adapter.push ? (path, title) => {
|
|
572
|
+
adapter.push?.(resolveRouteAdapterPath(adapter.getPath(), path), title);
|
|
573
|
+
} : void 0,
|
|
574
|
+
replace: adapter.replace ? (path, title) => {
|
|
575
|
+
adapter.replace?.(resolveRouteAdapterPath(adapter.getPath(), path), title);
|
|
576
|
+
} : void 0
|
|
577
|
+
};
|
|
578
|
+
wrappedRouteAdapterCache.set(adapter, wrappedAdapter);
|
|
579
|
+
return wrappedAdapter;
|
|
580
|
+
};
|
|
546
581
|
var getWindow2 = () => {
|
|
547
582
|
if (typeof globalThis === "undefined") {
|
|
548
583
|
return void 0;
|
|
@@ -576,7 +611,10 @@ var useBrowserLinkInterceptor = (adapter) => {
|
|
|
576
611
|
new URL(href);
|
|
577
612
|
return;
|
|
578
613
|
} catch (error) {
|
|
579
|
-
const nextPath =
|
|
614
|
+
const nextPath = resolveRouteAdapterPath(
|
|
615
|
+
WINDOW.location?.pathname ?? "",
|
|
616
|
+
href
|
|
617
|
+
);
|
|
580
618
|
event.preventDefault();
|
|
581
619
|
adapter.push?.(nextPath, title);
|
|
582
620
|
}
|
|
@@ -592,23 +630,27 @@ var RouteProvider = ({
|
|
|
592
630
|
initialPath,
|
|
593
631
|
children
|
|
594
632
|
}) => {
|
|
633
|
+
const normalizedAdapter = useMemo(
|
|
634
|
+
() => wrapRouteAdapterWithPathResolver(adapter),
|
|
635
|
+
[adapter]
|
|
636
|
+
);
|
|
595
637
|
const [currentPath, setCurrentPath] = useState(
|
|
596
|
-
initialPath ??
|
|
638
|
+
initialPath ?? normalizedAdapter.getPath()
|
|
597
639
|
);
|
|
598
640
|
useEffect(() => {
|
|
599
|
-
return
|
|
641
|
+
return normalizedAdapter.subscribe((nextPath) => {
|
|
600
642
|
setCurrentPath(nextPath);
|
|
601
643
|
});
|
|
602
|
-
}, [
|
|
644
|
+
}, [normalizedAdapter]);
|
|
603
645
|
const contextValue = useMemo(
|
|
604
646
|
() => ({
|
|
605
647
|
currentWindowPath: currentPath,
|
|
606
648
|
parentPath: "",
|
|
607
649
|
params: {},
|
|
608
650
|
isTopLevel: true,
|
|
609
|
-
adapter
|
|
651
|
+
adapter: normalizedAdapter
|
|
610
652
|
}),
|
|
611
|
-
[currentPath,
|
|
653
|
+
[currentPath, normalizedAdapter]
|
|
612
654
|
);
|
|
613
655
|
return /* @__PURE__ */ jsx(RouteContextProvider, { value: contextValue, children });
|
|
614
656
|
};
|
|
@@ -1140,4 +1182,4 @@ var AutoForm = ({
|
|
|
1140
1182
|
);
|
|
1141
1183
|
};
|
|
1142
1184
|
|
|
1143
|
-
export { AutoForm, AutoFormView, Route, RouteContext, RouteContextConsumer, RouteContextProvider, RouteProvider, buildHistoryPath, buildQueryString, buildRoutePath, canUseBrowserHistory, computeAreaBounds, createAutoField, createBrowserRouteAdapter, createFormRenderer, createHistoryBackHandler, createManualRouteAdapter, createMemoryHistory, createNativeRouteAdapter, createRouteAdapterFromHistory, createUniversalAdapter, defaultTranslateValidationErrorCode, getFieldKind, parseHistoryPath, parseTemplate, resolveSuite, useFormEngine, useRouteContext, validateAreas };
|
|
1185
|
+
export { AutoForm, AutoFormView, Route, RouteContext, RouteContextConsumer, RouteContextProvider, RouteProvider, buildHistoryPath, buildQueryString, buildRoutePath, canUseBrowserHistory, computeAreaBounds, createAutoField, createBrowserRouteAdapter, createFormRenderer, createHistoryBackHandler, createManualRouteAdapter, createMemoryHistory, createNativeRouteAdapter, createRouteAdapterFromHistory, createUniversalAdapter, defaultTranslateValidationErrorCode, getFieldKind, parseHistoryPath, parseTemplate, resolveSuite, useFormEngine, useRouteContext, validateAreas, wrapRouteAdapterWithPathResolver };
|
package/common/Routing.d.ts
CHANGED
|
@@ -56,6 +56,20 @@ export declare const mergeStringPaths: (path1: string, path2: string, delimiter?
|
|
|
56
56
|
* @returns Resolved path string.
|
|
57
57
|
* */
|
|
58
58
|
export declare const resolvePath: (currentPath: string, newPath: string) => string;
|
|
59
|
+
/**
|
|
60
|
+
* Resolve RouteAdapter navigation input against the current path.
|
|
61
|
+
*
|
|
62
|
+
* Rules:
|
|
63
|
+
* - `"/x"` resolves from root.
|
|
64
|
+
* - `"x"` and `"./x"` resolve under current path.
|
|
65
|
+
* - `"../x"` resolves one level up per `..`.
|
|
66
|
+
* - `"/"` and `""` both resolve to root (`"/"`).
|
|
67
|
+
*
|
|
68
|
+
* @param currentPath - Current absolute path (query/hash ignored).
|
|
69
|
+
* @param nextPath - Adapter navigation target (absolute or relative).
|
|
70
|
+
* @returns Resolved absolute path string.
|
|
71
|
+
*/
|
|
72
|
+
export declare const resolveRouteAdapterPath: (currentPath: string, nextPath: string) => string;
|
|
59
73
|
/**
|
|
60
74
|
* Get the parameter values from a path string and test the `path` against a `testPath`.
|
|
61
75
|
*
|
package/common/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export { ComparisonOperators, ITEM_RELATIONSHIP_DAC_RESOURCE_NAME, LogicalOperators, OperationGroup, RelationshipOperation, TypeInfoORMAPIRoutePaths, TypeInfoORMServiceError } from '../chunk-7AMEFPPP.js';
|
|
2
|
-
export { DENIED_TYPE_OPERATIONS, ERROR_MESSAGE_CONSTANTS, INVALID_CUSTOM_TYPE, PRIMITIVE_ERROR_MESSAGE_CONSTANTS, RelationshipValidationType, TYPE_KEYWORD_ERROR_MESSAGE_CONSTANTS, TYPE_KEYWORD_VALIDATORS, TypeOperation, getArrayItemErrorMap, getErrorDescriptor, getErrorDescriptors, getNoErrorDescriptor, getValidityValue, hasValue, isArrayErrorDescriptorCollection, validateArrayOfTypeInfoFieldValues, validateCustomType, validateKeywordType, validateTypeInfoDataItem, validateTypeInfoFieldOperationAllowed, validateTypeInfoFieldValue, validateTypeInfoValue, validateTypeOperationAllowed, validateValueMatchesPattern } from '../chunk-
|
|
3
|
-
import '../chunk-
|
|
2
|
+
export { DENIED_TYPE_OPERATIONS, ERROR_MESSAGE_CONSTANTS, INVALID_CUSTOM_TYPE, PRIMITIVE_ERROR_MESSAGE_CONSTANTS, RelationshipValidationType, TYPE_KEYWORD_ERROR_MESSAGE_CONSTANTS, TYPE_KEYWORD_VALIDATORS, TypeOperation, getArrayItemErrorMap, getErrorDescriptor, getErrorDescriptors, getNoErrorDescriptor, getValidityValue, hasValue, isArrayErrorDescriptorCollection, validateArrayOfTypeInfoFieldValues, validateCustomType, validateKeywordType, validateTypeInfoDataItem, validateTypeInfoFieldOperationAllowed, validateTypeInfoFieldValue, validateTypeInfoValue, validateTypeOperationAllowed, validateValueMatchesPattern } from '../chunk-C3LXDJM5.js';
|
|
3
|
+
import '../chunk-WNFRDIBW.js';
|
|
4
4
|
import '../chunk-I2KLQ2HA.js';
|
|
5
5
|
|
|
6
6
|
// src/common/CommandLine/collectRequiredEnvironmentVariables.ts
|
package/native/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { computeTrackPixels } from '../chunk-TJFTWPXQ.js';
|
|
2
|
-
import { createFormRenderer, createHistoryBackHandler, buildHistoryPath, AutoFormView, AutoForm, parseTemplate, validateAreas, computeAreaBounds, parseHistoryPath, createMemoryHistory, Route, buildRoutePath } from '../chunk-
|
|
3
|
-
import { ERROR_MESSAGE_CONSTANTS } from '../chunk-
|
|
4
|
-
import { getPathArray } from '../chunk-
|
|
2
|
+
import { createFormRenderer, createHistoryBackHandler, buildHistoryPath, AutoFormView, AutoForm, parseTemplate, validateAreas, computeAreaBounds, parseHistoryPath, createMemoryHistory, Route, buildRoutePath } from '../chunk-Z7T6VEWO.js';
|
|
3
|
+
import { ERROR_MESSAGE_CONSTANTS } from '../chunk-C3LXDJM5.js';
|
|
4
|
+
import { resolveRouteAdapterPath, getPathArray } from '../chunk-WNFRDIBW.js';
|
|
5
5
|
import '../chunk-I2KLQ2HA.js';
|
|
6
6
|
import { createElement, useMemo } from 'react';
|
|
7
7
|
import { Text, View, Platform, Switch, TextInput, Pressable, BackHandler } from 'react-native';
|
|
@@ -658,13 +658,14 @@ var createNativeHistory = (options = {}) => {
|
|
|
658
658
|
var createNativeBackHandler = (history) => createHistoryBackHandler(history);
|
|
659
659
|
var createNavigationStateRouteAdapter = (options) => {
|
|
660
660
|
const getPath = () => options.toPath(options.getState());
|
|
661
|
+
const resolvePath = (path) => resolveRouteAdapterPath(getPath(), path);
|
|
661
662
|
return {
|
|
662
663
|
getPath,
|
|
663
664
|
subscribe: (listener) => options.subscribe(() => {
|
|
664
665
|
listener(getPath());
|
|
665
666
|
}),
|
|
666
|
-
push: options.navigate ? (path) => options.navigate?.(path) : void 0,
|
|
667
|
-
replace: options.replace ? (path) => options.replace?.(path) : void 0
|
|
667
|
+
push: options.navigate ? (path) => options.navigate?.(resolvePath(path)) : void 0,
|
|
668
|
+
replace: options.replace ? (path) => options.replace?.(resolvePath(path)) : void 0
|
|
668
669
|
};
|
|
669
670
|
};
|
|
670
671
|
var createNativeHardwareBackHandler = (adapter) => {
|
package/package.json
CHANGED
package/web/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { createEasyLayout } from '../chunk-
|
|
2
|
-
import { createFormRenderer, AutoFormView, AutoForm, createBrowserRouteAdapter, Route } from '../chunk-
|
|
3
|
-
import { ERROR_MESSAGE_CONSTANTS } from '../chunk-
|
|
4
|
-
import '../chunk-
|
|
1
|
+
import { createEasyLayout } from '../chunk-TNQLXU6L.js';
|
|
2
|
+
import { createFormRenderer, AutoFormView, AutoForm, createBrowserRouteAdapter, Route } from '../chunk-Z7T6VEWO.js';
|
|
3
|
+
import { ERROR_MESSAGE_CONSTANTS } from '../chunk-C3LXDJM5.js';
|
|
4
|
+
import '../chunk-WNFRDIBW.js';
|
|
5
5
|
import { __export, __reExport } from '../chunk-I2KLQ2HA.js';
|
|
6
6
|
import { createElement, useCallback, useRef } from 'react';
|
|
7
7
|
import * as styledBase from 'styled-components';
|