@g9tm/lynxcontrols 1.4.11 → 1.5.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/dist/.tsbuildinfo +1 -1
- package/dist/anchor/context.d.ts +15 -0
- package/dist/anchor/context.d.ts.map +1 -0
- package/dist/anchor/context.jsx +10 -0
- package/dist/anchor/context.jsx.map +1 -0
- package/dist/anchor/hooks.d.ts +72 -0
- package/dist/anchor/hooks.d.ts.map +1 -0
- package/dist/anchor/hooks.jsx +147 -0
- package/dist/anchor/hooks.jsx.map +1 -0
- package/dist/anchor/index.d.ts +6 -0
- package/dist/anchor/index.d.ts.map +1 -0
- package/dist/anchor/index.jsx +5 -0
- package/dist/anchor/measure.d.ts +22 -0
- package/dist/anchor/measure.d.ts.map +1 -0
- package/dist/anchor/measure.jsx +110 -0
- package/dist/anchor/measure.jsx.map +1 -0
- package/dist/anchor/registry.d.ts +108 -0
- package/dist/anchor/registry.d.ts.map +1 -0
- package/dist/anchor/registry.jsx +142 -0
- package/dist/anchor/registry.jsx.map +1 -0
- package/dist/anchor/scroll.d.ts +34 -0
- package/dist/anchor/scroll.d.ts.map +1 -0
- package/dist/anchor/scroll.jsx +255 -0
- package/dist/anchor/scroll.jsx.map +1 -0
- package/dist/base/control.d.ts +10 -3
- package/dist/base/control.d.ts.map +1 -1
- package/dist/base/control.jsx +17 -2
- package/dist/base/control.jsx.map +1 -1
- package/dist/base/pressable.d.ts.map +1 -1
- package/dist/base/pressable.jsx +7 -1
- package/dist/base/pressable.jsx.map +1 -1
- package/dist/button/button.d.ts.map +1 -1
- package/dist/button/button.jsx +11 -1
- package/dist/button/button.jsx.map +1 -1
- package/dist/button/header-action-button.d.ts.map +1 -1
- package/dist/button/header-action-button.jsx +10 -1
- package/dist/button/header-action-button.jsx.map +1 -1
- package/dist/button/icon-button.d.ts.map +1 -1
- package/dist/button/icon-button.jsx +11 -1
- package/dist/button/icon-button.jsx.map +1 -1
- package/dist/button/nav-card.d.ts.map +1 -1
- package/dist/button/nav-card.jsx +10 -1
- package/dist/button/nav-card.jsx.map +1 -1
- package/dist/button/vertical-icon-text-button.d.ts.map +1 -1
- package/dist/button/vertical-icon-text-button.jsx +10 -1
- package/dist/button/vertical-icon-text-button.jsx.map +1 -1
- package/dist/expander/expander.d.ts.map +1 -1
- package/dist/expander/expander.jsx +14 -1
- package/dist/expander/expander.jsx.map +1 -1
- package/dist/fields/editor.d.ts.map +1 -1
- package/dist/fields/editor.jsx +17 -1
- package/dist/fields/editor.jsx.map +1 -1
- package/dist/fields/outlined-field.d.ts +6 -0
- package/dist/fields/outlined-field.d.ts.map +1 -1
- package/dist/fields/outlined-field.jsx +14 -3
- package/dist/fields/outlined-field.jsx.map +1 -1
- package/dist/fields/text-entry.d.ts.map +1 -1
- package/dist/fields/text-entry.jsx +17 -1
- package/dist/fields/text-entry.jsx.map +1 -1
- package/dist/guide/guide.css +453 -0
- package/dist/guide/guide.css.map +1 -0
- package/dist/guide/index.d.ts +5 -0
- package/dist/guide/index.d.ts.map +1 -0
- package/dist/guide/index.jsx +4 -0
- package/dist/guide/journey.d.ts +46 -0
- package/dist/guide/journey.d.ts.map +1 -0
- package/dist/guide/journey.jsx +464 -0
- package/dist/guide/journey.jsx.map +1 -0
- package/dist/guide/placement.d.ts +44 -0
- package/dist/guide/placement.d.ts.map +1 -0
- package/dist/guide/placement.jsx +119 -0
- package/dist/guide/placement.jsx.map +1 -0
- package/dist/guide/service.d.ts +85 -0
- package/dist/guide/service.d.ts.map +1 -0
- package/dist/guide/service.jsx +620 -0
- package/dist/guide/service.jsx.map +1 -0
- package/dist/guide/settings.d.ts +50 -0
- package/dist/guide/settings.d.ts.map +1 -0
- package/dist/guide/settings.jsx +60 -0
- package/dist/guide/settings.jsx.map +1 -0
- package/dist/host/host.d.ts +5 -1
- package/dist/host/host.d.ts.map +1 -1
- package/dist/host/host.jsx +12 -0
- package/dist/host/host.jsx.map +1 -1
- package/dist/host/layers.d.ts +3 -1
- package/dist/host/layers.d.ts.map +1 -1
- package/dist/host/layers.jsx +4 -2
- package/dist/host/layers.jsx.map +1 -1
- package/dist/host/registry.d.ts +3 -0
- package/dist/host/registry.d.ts.map +1 -1
- package/dist/host/registry.jsx.map +1 -1
- package/dist/index.d.ts +3 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/provider/contexts.d.ts +3 -0
- package/dist/provider/contexts.d.ts.map +1 -1
- package/dist/provider/contexts.jsx.map +1 -1
- package/dist/provider/provider.d.ts.map +1 -1
- package/dist/provider/provider.jsx +24 -17
- package/dist/provider/provider.jsx.map +1 -1
- package/dist/provider/settings.d.ts +4 -0
- package/dist/provider/settings.d.ts.map +1 -1
- package/dist/provider/settings.jsx +3 -2
- package/dist/provider/settings.jsx.map +1 -1
- package/dist/route/hooks.d.ts +34 -0
- package/dist/route/hooks.d.ts.map +1 -0
- package/dist/route/hooks.jsx +147 -0
- package/dist/route/hooks.jsx.map +1 -0
- package/dist/route/index.d.ts +3 -0
- package/dist/route/index.d.ts.map +1 -0
- package/dist/route/index.jsx +2 -0
- package/dist/route/router.d.ts +201 -0
- package/dist/route/router.d.ts.map +1 -0
- package/dist/route/router.jsx +810 -0
- package/dist/route/router.jsx.map +1 -0
- package/dist/sheet/frame.d.ts +3 -1
- package/dist/sheet/frame.d.ts.map +1 -1
- package/dist/sheet/frame.jsx +67 -25
- package/dist/sheet/frame.jsx.map +1 -1
- package/dist/sheet/options.d.ts +10 -0
- package/dist/sheet/options.d.ts.map +1 -1
- package/dist/sheet/options.jsx.map +1 -1
- package/dist/sheet/service.d.ts +5 -0
- package/dist/sheet/service.d.ts.map +1 -1
- package/dist/sheet/service.jsx +14 -2
- package/dist/sheet/service.jsx.map +1 -1
- package/dist/sheet/sheet.css +9 -0
- package/dist/sheet/sheet.css.map +1 -1
- package/dist/tabs/tab-view.d.ts +14 -0
- package/dist/tabs/tab-view.d.ts.map +1 -1
- package/dist/tabs/tab-view.jsx +59 -3
- package/dist/tabs/tab-view.jsx.map +1 -1
- package/dist/toggle/checkbox.d.ts.map +1 -1
- package/dist/toggle/checkbox.jsx +15 -1
- package/dist/toggle/checkbox.jsx.map +1 -1
- package/dist/toggle/chip-group.d.ts.map +1 -1
- package/dist/toggle/chip-group.jsx +12 -1
- package/dist/toggle/chip-group.jsx.map +1 -1
- package/dist/toggle/switch.d.ts.map +1 -1
- package/dist/toggle/switch.jsx +15 -1
- package/dist/toggle/switch.jsx.map +1 -1
- package/package.json +17 -2
|
@@ -0,0 +1,147 @@
|
|
|
1
|
+
import { formatAddress, toSegment } from "@g9tm/lynxcontrols-foundation";
|
|
2
|
+
import { useContext, useEffect, useRef, useSyncExternalStore } from "@lynx-js/react";
|
|
3
|
+
import { G9CoreContext } from "../provider/contexts.jsx";
|
|
4
|
+
import { isG9Router } from "./router.jsx";
|
|
5
|
+
function useG9RouteSink() {
|
|
6
|
+
var _ref;
|
|
7
|
+
var _useContext;
|
|
8
|
+
return null != (_ref = null == (_useContext = useContext(G9CoreContext)) ? void 0 : _useContext.services.route) ? _ref : null;
|
|
9
|
+
}
|
|
10
|
+
function useG9Router() {
|
|
11
|
+
const sink = useG9RouteSink();
|
|
12
|
+
return isG9Router(sink) ? sink : null;
|
|
13
|
+
}
|
|
14
|
+
const NO_LOCATION = ()=>()=>{};
|
|
15
|
+
const NULL = ()=>null;
|
|
16
|
+
function useG9Location() {
|
|
17
|
+
const router = useG9Router();
|
|
18
|
+
return useSyncExternalStore(router ? (l)=>router.current.subscribe(l) : NO_LOCATION, router ? ()=>router.current.get() : NULL);
|
|
19
|
+
}
|
|
20
|
+
function segmentText(spec) {
|
|
21
|
+
try {
|
|
22
|
+
const s = 'function' == typeof spec.segment ? spec.segment() : spec.segment;
|
|
23
|
+
return formatAddress([
|
|
24
|
+
toSegment(s)
|
|
25
|
+
]);
|
|
26
|
+
} catch {
|
|
27
|
+
return '';
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
function useG9Place(spec, options = {}) {
|
|
31
|
+
var _options_active, _spec_order;
|
|
32
|
+
const ownSink = useG9RouteSink();
|
|
33
|
+
const sink = void 0 !== options.sink ? options.sink : ownSink;
|
|
34
|
+
const latest = useRef(spec);
|
|
35
|
+
latest.current = spec;
|
|
36
|
+
const handle = useRef(null);
|
|
37
|
+
const lastText = useRef('');
|
|
38
|
+
const active = null != (_options_active = options.active) ? _options_active : true;
|
|
39
|
+
const key = spec && active ? `${spec.layer}|${null != (_spec_order = spec.order) ? _spec_order : 0}|${spec.under ? formatAddress(spec.under) : ''}` : null;
|
|
40
|
+
useEffect(()=>{
|
|
41
|
+
if (!sink || null === key) return;
|
|
42
|
+
const first = latest.current;
|
|
43
|
+
const read = ()=>{
|
|
44
|
+
var _latest_current;
|
|
45
|
+
const s = (null != (_latest_current = latest.current) ? _latest_current : first).segment;
|
|
46
|
+
return toSegment('function' == typeof s ? s() : s);
|
|
47
|
+
};
|
|
48
|
+
const call = (k)=>{
|
|
49
|
+
var _latest_current;
|
|
50
|
+
return (null != (_latest_current = latest.current) ? _latest_current : first)[k];
|
|
51
|
+
};
|
|
52
|
+
const declaration = {
|
|
53
|
+
segment: read,
|
|
54
|
+
layer: first.layer,
|
|
55
|
+
...void 0 !== first.order ? {
|
|
56
|
+
order: first.order
|
|
57
|
+
} : {},
|
|
58
|
+
...first.under ? {
|
|
59
|
+
under: first.under
|
|
60
|
+
} : {},
|
|
61
|
+
...first.title ? {
|
|
62
|
+
title: ()=>{
|
|
63
|
+
var _call;
|
|
64
|
+
return null == (_call = call('title')) ? void 0 : _call();
|
|
65
|
+
}
|
|
66
|
+
} : {},
|
|
67
|
+
...first.view ? {
|
|
68
|
+
view: ()=>{
|
|
69
|
+
var _call;
|
|
70
|
+
return null == (_call = call('view')) ? void 0 : _call();
|
|
71
|
+
}
|
|
72
|
+
} : {},
|
|
73
|
+
...first.applyView ? {
|
|
74
|
+
applyView: (v)=>{
|
|
75
|
+
var _call;
|
|
76
|
+
return null == (_call = call('applyView')) ? void 0 : _call(v);
|
|
77
|
+
}
|
|
78
|
+
} : {},
|
|
79
|
+
...first.close ? {
|
|
80
|
+
close: ()=>{
|
|
81
|
+
var _call;
|
|
82
|
+
return null == (_call = call('close')) ? void 0 : _call();
|
|
83
|
+
}
|
|
84
|
+
} : {},
|
|
85
|
+
...first.canLeave ? {
|
|
86
|
+
canLeave: ()=>{
|
|
87
|
+
var _ref;
|
|
88
|
+
var _call;
|
|
89
|
+
return null != (_ref = null == (_call = call('canLeave')) ? void 0 : _call()) ? _ref : true;
|
|
90
|
+
}
|
|
91
|
+
} : {},
|
|
92
|
+
...first.describeChanges ? {
|
|
93
|
+
describeChanges: ()=>{
|
|
94
|
+
var _ref;
|
|
95
|
+
var _call;
|
|
96
|
+
return null != (_ref = null == (_call = call('describeChanges')) ? void 0 : _call()) ? _ref : [];
|
|
97
|
+
}
|
|
98
|
+
} : {},
|
|
99
|
+
...first.facts ? {
|
|
100
|
+
facts: ()=>{
|
|
101
|
+
var _ref;
|
|
102
|
+
var _call;
|
|
103
|
+
return null != (_ref = null == (_call = call('facts')) ? void 0 : _call()) ? _ref : {};
|
|
104
|
+
}
|
|
105
|
+
} : {}
|
|
106
|
+
};
|
|
107
|
+
lastText.current = segmentText(first);
|
|
108
|
+
const h = sink.declare(declaration);
|
|
109
|
+
handle.current = h;
|
|
110
|
+
return ()=>{
|
|
111
|
+
h.remove();
|
|
112
|
+
if (handle.current === h) handle.current = null;
|
|
113
|
+
};
|
|
114
|
+
}, [
|
|
115
|
+
sink,
|
|
116
|
+
key
|
|
117
|
+
]);
|
|
118
|
+
useEffect(()=>{
|
|
119
|
+
if (!spec || !handle.current) return;
|
|
120
|
+
const text = segmentText(spec);
|
|
121
|
+
if (text === lastText.current) return;
|
|
122
|
+
lastText.current = text;
|
|
123
|
+
handle.current.touch();
|
|
124
|
+
});
|
|
125
|
+
}
|
|
126
|
+
function G9Place(props) {
|
|
127
|
+
const { children, active, ...spec } = props;
|
|
128
|
+
useG9Place(spec, void 0 === active ? {} : {
|
|
129
|
+
active
|
|
130
|
+
});
|
|
131
|
+
return <>{children}</>;
|
|
132
|
+
}
|
|
133
|
+
function sheetSegmentOf(automationId) {
|
|
134
|
+
if (!automationId) return {
|
|
135
|
+
kind: 'sheet'
|
|
136
|
+
};
|
|
137
|
+
const kebab = automationId.replace(/([a-z0-9])([A-Z])/g, '$1-$2').replace(/[^A-Za-z0-9]+/g, '-').replace(/^-+|-+$/g, '').toLowerCase().replace(/^[^a-z]+/, '').slice(0, 32).replace(/-+$/, '');
|
|
138
|
+
return kebab ? {
|
|
139
|
+
kind: 'sheet',
|
|
140
|
+
variant: kebab
|
|
141
|
+
} : {
|
|
142
|
+
kind: 'sheet'
|
|
143
|
+
};
|
|
144
|
+
}
|
|
145
|
+
export { G9Place, sheetSegmentOf, useG9Location, useG9Place, useG9RouteSink, useG9Router };
|
|
146
|
+
|
|
147
|
+
//# sourceMappingURL=hooks.jsx.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"route/hooks.jsx","sources":["../../src/route/hooks.tsx"],"sourcesContent":["import {\n formatAddress,\n type G9PlaceDeclaration,\n type G9PlaceHandle,\n type G9PlaceLayer,\n type G9RouteSink,\n type G9Segment,\n type G9SegmentInput,\n toSegment,\n} from '@g9tm/lynxcontrols-foundation';\nimport { type ReactNode, useContext, useEffect, useRef, useSyncExternalStore } from '@lynx-js/react';\nimport { G9CoreContext } from '../provider/contexts';\nimport { type G9Location, type G9Router, isG9Router } from './router';\n\n/** A place a component declares while it is open. */\nexport interface G9PlaceSpec extends Omit<G9PlaceDeclaration, 'segment' | 'layer'> {\n readonly segment: G9SegmentInput | (() => G9SegmentInput);\n readonly layer: G9PlaceLayer;\n}\n\n/** The route sink of the provider (`services.route`), or null without one. */\nexport function useG9RouteSink(): G9RouteSink | null {\n return useContext(G9CoreContext)?.services.route ?? null;\n}\n\n/** The provider's router when the sink is one, else null. */\nexport function useG9Router(): G9Router | null {\n const sink = useG9RouteSink();\n return isG9Router(sink) ? sink : null;\n}\n\nconst NO_LOCATION = () => () => {};\nconst NULL = () => null;\n\n/** Where the app is (re-renders on every change), or null without a router. */\nexport function useG9Location(): G9Location | null {\n const router = useG9Router();\n return useSyncExternalStore(\n router ? (l) => router.current.subscribe(l) : NO_LOCATION,\n router ? () => router.current.get() : NULL,\n );\n}\n\nfunction segmentText(spec: G9PlaceSpec): string {\n try {\n const s = typeof spec.segment === 'function' ? spec.segment() : spec.segment;\n return formatAddress([toSegment(s)]);\n } catch {\n return '';\n }\n}\n\n/**\n * Declares a place while mounted, `spec` is not null and `active` is true (a kept-alive tab body passes its own\n * `active`). The spec may change every render: the router reads the latest; a new segment touches the declaration, a\n * new layer, order or `under` declares it again. Which optional parts the place has (close, canLeave…) is fixed by the\n * first declaration of a mount.\n */\nexport function useG9Place(\n spec: G9PlaceSpec | null,\n options: { readonly active?: boolean; readonly sink?: G9RouteSink | null } = {},\n): void {\n const ownSink = useG9RouteSink();\n const sink = options.sink !== undefined ? options.sink : ownSink;\n const latest = useRef(spec);\n latest.current = spec;\n const handle = useRef<G9PlaceHandle | null>(null);\n const lastText = useRef('');\n const active = options.active ?? true;\n const key = spec && active ? `${spec.layer}|${spec.order ?? 0}|${spec.under ? formatAddress(spec.under) : ''}` : null;\n\n useEffect(() => {\n if (!sink || key === null) return undefined;\n const first = latest.current as G9PlaceSpec;\n const read = (): G9Segment => {\n const s = (latest.current ?? first).segment;\n return toSegment(typeof s === 'function' ? s() : s);\n };\n const call = <K extends keyof G9PlaceSpec>(k: K) => (latest.current ?? first)[k] as G9PlaceSpec[K];\n const declaration: G9PlaceDeclaration = {\n segment: read,\n layer: first.layer,\n ...(first.order !== undefined ? { order: first.order } : {}),\n ...(first.under ? { under: first.under } : {}),\n ...(first.title ? { title: () => call('title')?.() } : {}),\n ...(first.view ? { view: () => call('view')?.() } : {}),\n ...(first.applyView ? { applyView: (v: Readonly<Record<string, string>>) => call('applyView')?.(v) } : {}),\n ...(first.close ? { close: () => call('close')?.() } : {}),\n ...(first.canLeave ? { canLeave: () => call('canLeave')?.() ?? true } : {}),\n ...(first.describeChanges ? { describeChanges: () => call('describeChanges')?.() ?? [] } : {}),\n ...(first.facts ? { facts: () => call('facts')?.() ?? {} } : {}),\n };\n lastText.current = segmentText(first);\n const h = sink.declare(declaration);\n handle.current = h;\n return () => {\n h.remove();\n if (handle.current === h) handle.current = null;\n };\n }, [sink, key]);\n\n useEffect(() => {\n if (!spec || !handle.current) return;\n const text = segmentText(spec);\n if (text === lastText.current) return;\n lastText.current = text;\n handle.current.touch();\n });\n}\n\n/** Props of {@link G9Place}. */\nexport interface G9PlaceProps extends G9PlaceSpec {\n readonly active?: boolean;\n readonly children?: ReactNode;\n}\n\n/** Declares a place around its children (renders no element). */\nexport function G9Place(props: G9PlaceProps): ReactNode {\n const { children, active, ...spec } = props;\n useG9Place(spec, active === undefined ? {} : { active });\n return <>{children}</>;\n}\n\n/** The segment of a sheet without an explicit route: `sheet.<its automation id in kebab case>`, else `sheet`. */\nexport function sheetSegmentOf(automationId: string | undefined | null): G9Segment {\n if (!automationId) return { kind: 'sheet' };\n const kebab = automationId\n .replace(/([a-z0-9])([A-Z])/g, '$1-$2')\n .replace(/[^A-Za-z0-9]+/g, '-')\n .replace(/^-+|-+$/g, '')\n .toLowerCase()\n .replace(/^[^a-z]+/, '')\n .slice(0, 32)\n .replace(/-+$/, '');\n return kebab ? { kind: 'sheet', variant: kebab } : { kind: 'sheet' };\n}\n"],"names":["useG9RouteSink","_useContext","G9CoreContext","useG9Router","sink","isG9Router","NO_LOCATION","NULL","useG9Location","router","useSyncExternalStore","l","segmentText","spec","s","formatAddress","toSegment","useG9Place","options","_options_active","_spec_order","ownSink","undefined","latest","useRef","handle","lastText","active","key","useEffect","first","read","_latest_current","call","k","declaration","_call","v","h","text","G9Place","props","children","sheetSegmentOf","automationId","kebab"],"mappings":";;;;AAqBO,SAASA;;QACPC;IAAP,OAAO,QAAP,gBAAOA,CAAAA,cAAAA,WAAWC,cAAaA,IAAxBD,KAAA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AO,CAAC,OAAO;IAClB,OAAOC,QAAQ;QAAE,MAAM;QAAS,SAASA;IAAM,IAAI;QAAE,MAAM;IAAQ;AACrE"}
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
export { G9Place, type G9PlaceProps, type G9PlaceSpec, sheetSegmentOf, useG9Location, useG9Place, useG9Router, useG9RouteSink, } from './hooks.js';
|
|
2
|
+
export { createG9Router, type G9Excursion, type G9GoOptions, type G9GoResult, type G9GoSource, type G9Location, type G9ReadableStore, type G9RouteEvent, type G9Router, type G9RouterOptions, type G9RouterTexts, type G9TrailEntry, type G9Walk, type G9WalkOptions, type G9WalkPresenter, type G9WalkStep, isG9Router, } from './router.js';
|
|
3
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/route/index.ts"],"names":[],"mappings":"AAKA,OAAO,EACL,OAAO,EACP,KAAK,YAAY,EACjB,KAAK,WAAW,EAChB,cAAc,EACd,aAAa,EACb,UAAU,EACV,WAAW,EACX,cAAc,GACf,MAAM,SAAS,CAAC;AACjB,OAAO,EACL,cAAc,EACd,KAAK,WAAW,EAChB,KAAK,WAAW,EAChB,KAAK,UAAU,EACf,KAAK,UAAU,EACf,KAAK,UAAU,EACf,KAAK,eAAe,EACpB,KAAK,YAAY,EACjB,KAAK,QAAQ,EACb,KAAK,eAAe,EACpB,KAAK,aAAa,EAClB,KAAK,YAAY,EACjB,KAAK,MAAM,EACX,KAAK,aAAa,EAClB,KAAK,eAAe,EACpB,KAAK,UAAU,EACf,UAAU,GACX,MAAM,UAAU,CAAC"}
|
|
@@ -0,0 +1,201 @@
|
|
|
1
|
+
import { type G9Address, type G9Catalogue, type G9GoFailure, type G9PlaceDeclaration, type G9PlaceLayer, type G9RouteSink, type G9Segment, type G9SegmentView, type G9Snapshot, type G9ViewApplied } from '@g9tm/lynxcontrols-foundation';
|
|
2
|
+
import type { G9AnchorRegistry } from '../anchor/registry.js';
|
|
3
|
+
/** A store a component reads with `useSyncExternalStore`. */
|
|
4
|
+
export interface G9ReadableStore<T> {
|
|
5
|
+
get(): T;
|
|
6
|
+
subscribe(listener: () => void): () => void;
|
|
7
|
+
}
|
|
8
|
+
/** Where the app is. The same object until something changes. */
|
|
9
|
+
export interface G9Location {
|
|
10
|
+
/** The unique address (canonical, ids included, no target). */
|
|
11
|
+
readonly unique: string;
|
|
12
|
+
/** The general address (kinds only). */
|
|
13
|
+
readonly general: string;
|
|
14
|
+
readonly segments: readonly G9Segment[];
|
|
15
|
+
/** A breadcrumb per segment, in the current language. */
|
|
16
|
+
readonly titles: readonly string[];
|
|
17
|
+
/** The path does not reach the root (a parent was missing). */
|
|
18
|
+
readonly incomplete: boolean;
|
|
19
|
+
/** Open places that are not on the path, as general segments (`site`, `map`). */
|
|
20
|
+
readonly others: readonly string[];
|
|
21
|
+
/** Facts the open places report (the surface, the open site…). */
|
|
22
|
+
readonly facts: Readonly<Record<string, string | number | boolean | null>>;
|
|
23
|
+
readonly revision: number;
|
|
24
|
+
}
|
|
25
|
+
/** One move in the trail. */
|
|
26
|
+
export interface G9TrailEntry {
|
|
27
|
+
readonly at: number;
|
|
28
|
+
readonly unique: string;
|
|
29
|
+
readonly general: string;
|
|
30
|
+
readonly cause: 'user' | 'go' | 'walk' | 'restore' | 'back';
|
|
31
|
+
}
|
|
32
|
+
/** How a navigation ended: where the app is, or the reason, the step and a message for the person. */
|
|
33
|
+
export type G9GoResult = {
|
|
34
|
+
readonly ok: true;
|
|
35
|
+
readonly location: G9Location;
|
|
36
|
+
readonly view: G9ViewApplied;
|
|
37
|
+
} | {
|
|
38
|
+
readonly ok: false;
|
|
39
|
+
readonly reason: G9GoFailure;
|
|
40
|
+
/** The segment index it stopped at (-1: before any). */
|
|
41
|
+
readonly at: number;
|
|
42
|
+
readonly segment: G9Segment | null;
|
|
43
|
+
/** For the person, in their language when the place said so; otherwise for developers. */
|
|
44
|
+
readonly message: string;
|
|
45
|
+
readonly location: G9Location;
|
|
46
|
+
};
|
|
47
|
+
/** Who asked for a navigation. */
|
|
48
|
+
export type G9GoSource = 'user' | 'assistant' | 'link' | 'tester' | 'qa' | 'restore';
|
|
49
|
+
/** How a navigation runs: who asked, snapshot views to put back, whether QA may force past unsaved work. */
|
|
50
|
+
export interface G9GoOptions {
|
|
51
|
+
readonly source?: G9GoSource;
|
|
52
|
+
/** Apply snapshot views (scroll marks, view values). `restore` does. */
|
|
53
|
+
readonly views?: readonly G9SegmentView[];
|
|
54
|
+
/** Close dirty places without asking: honoured for `qa` only. */
|
|
55
|
+
readonly force?: boolean;
|
|
56
|
+
}
|
|
57
|
+
/** What the router reports (diagnostics, busy tracking, a tester trail). */
|
|
58
|
+
export type G9RouteEvent = {
|
|
59
|
+
readonly kind: 'changed';
|
|
60
|
+
readonly location: G9Location;
|
|
61
|
+
readonly cause: G9TrailEntry['cause'];
|
|
62
|
+
} | {
|
|
63
|
+
readonly kind: 'go:start';
|
|
64
|
+
readonly address: string;
|
|
65
|
+
readonly mode: 'jump' | 'walk' | 'restore';
|
|
66
|
+
} | {
|
|
67
|
+
readonly kind: 'go:step';
|
|
68
|
+
readonly address: string;
|
|
69
|
+
readonly index: number;
|
|
70
|
+
readonly segment: G9Segment;
|
|
71
|
+
readonly how: 'opened' | 'walked' | 'jumped';
|
|
72
|
+
} | {
|
|
73
|
+
readonly kind: 'go:done';
|
|
74
|
+
readonly address: string;
|
|
75
|
+
readonly result: G9GoResult;
|
|
76
|
+
} | {
|
|
77
|
+
readonly kind: 'error';
|
|
78
|
+
readonly where: string;
|
|
79
|
+
readonly error: unknown;
|
|
80
|
+
};
|
|
81
|
+
/** One step of a walk. */
|
|
82
|
+
export interface G9WalkStep {
|
|
83
|
+
readonly index: number;
|
|
84
|
+
readonly segment: G9Segment;
|
|
85
|
+
readonly title: string;
|
|
86
|
+
readonly state: 'pending' | 'current' | 'done' | 'jumped' | 'failed';
|
|
87
|
+
}
|
|
88
|
+
/** Draws a walk step: the guide module's default presenter points a finger at the entry control. */
|
|
89
|
+
export interface G9WalkPresenter {
|
|
90
|
+
show(step: {
|
|
91
|
+
readonly anchor: string;
|
|
92
|
+
readonly text: string;
|
|
93
|
+
readonly gesture: 'tap' | 'longPress';
|
|
94
|
+
readonly index: number;
|
|
95
|
+
readonly count: number;
|
|
96
|
+
}): {
|
|
97
|
+
hide(): void;
|
|
98
|
+
};
|
|
99
|
+
/** A step the router does itself (a jump, a preparation): one short line. */
|
|
100
|
+
note?(text: string): void;
|
|
101
|
+
}
|
|
102
|
+
/** How a walk runs: the person taps (`user`) or the router presses (`demo`), and who draws the steps. */
|
|
103
|
+
export interface G9WalkOptions extends G9GoOptions {
|
|
104
|
+
/** `user` waits for the person's own tap; `demo` presses the entry itself. Default `user`. */
|
|
105
|
+
readonly by?: 'user' | 'demo';
|
|
106
|
+
readonly presenter?: G9WalkPresenter;
|
|
107
|
+
/** Per step. Default 60000 (user) / 8000 (demo). */
|
|
108
|
+
readonly stepTimeoutMs?: number;
|
|
109
|
+
/** How long a demo shows the control before pressing it. Default 900 ms. */
|
|
110
|
+
readonly demoDelayMs?: number;
|
|
111
|
+
}
|
|
112
|
+
/** A guided navigation in progress: its steps, cancel, and its result. */
|
|
113
|
+
export interface G9Walk {
|
|
114
|
+
readonly steps: G9ReadableStore<readonly G9WalkStep[]>;
|
|
115
|
+
cancel(): void;
|
|
116
|
+
readonly result: Promise<G9GoResult>;
|
|
117
|
+
}
|
|
118
|
+
/** A trip somewhere and back. */
|
|
119
|
+
export interface G9Excursion {
|
|
120
|
+
readonly origin: G9Snapshot;
|
|
121
|
+
readonly result: G9GoResult;
|
|
122
|
+
back(): Promise<G9GoResult>;
|
|
123
|
+
}
|
|
124
|
+
/** What a router is built from: the catalogue, the context and language its callbacks get, the anchors, texts. */
|
|
125
|
+
export interface G9RouterOptions<Ctx> {
|
|
126
|
+
readonly catalogue: G9Catalogue<Ctx>;
|
|
127
|
+
/** What every catalogue callback gets; null = nobody signed in (only places without guards resolve). */
|
|
128
|
+
context(): Ctx | null;
|
|
129
|
+
language(): 'fa' | 'en';
|
|
130
|
+
readonly anchors?: () => G9AnchorRegistry | null;
|
|
131
|
+
/** Wall clock (ms). Default `Date.now`. */
|
|
132
|
+
now?(): number;
|
|
133
|
+
/** Asked before closing a place with unsaved work. Absent = such a navigation is refused (`dirty`). */
|
|
134
|
+
confirmLeave?(segment: G9Segment, title: string, message: string | undefined): Promise<boolean>;
|
|
135
|
+
onEvent?(event: G9RouteEvent): void;
|
|
136
|
+
/** Default 50. */
|
|
137
|
+
readonly historySize?: number;
|
|
138
|
+
/**
|
|
139
|
+
* After a sheet appeared, how long before the next place is opened (G9 sheets drop a second show within 369 ms, the
|
|
140
|
+
* double-tap guard). Default 410.
|
|
141
|
+
*/
|
|
142
|
+
readonly sheetGapMs?: number;
|
|
143
|
+
/** How long a closing place may take to go (ms). Default 3000. */
|
|
144
|
+
readonly closeTimeoutMs?: number;
|
|
145
|
+
/**
|
|
146
|
+
* How long an address's `#target` may take to appear after its place opened (ms) — a list fills after its sheet is
|
|
147
|
+
* declared. Default 3000.
|
|
148
|
+
*/
|
|
149
|
+
readonly targetTimeoutMs?: number;
|
|
150
|
+
/** After restoring a scroll mark: how long the rows must stay unchanged before it is applied again (ms). Default 400. */
|
|
151
|
+
readonly scrollSettleMs?: number;
|
|
152
|
+
/** …and the longest wait for that (ms). Default 3000. */
|
|
153
|
+
readonly scrollSettleMaxMs?: number;
|
|
154
|
+
/** The app version written into snapshots. */
|
|
155
|
+
readonly appVersion?: string | (() => string);
|
|
156
|
+
/** Texts the router shows a person (default: English developer texts). */
|
|
157
|
+
readonly texts?: Partial<G9RouterTexts>;
|
|
158
|
+
}
|
|
159
|
+
/** What the router tells a person, in their language (the app supplies them). */
|
|
160
|
+
export interface G9RouterTexts {
|
|
161
|
+
notFound(title: string): string;
|
|
162
|
+
blocked(title: string): string;
|
|
163
|
+
timeout(title: string): string;
|
|
164
|
+
/** `open` said it could not open the place (the app already told the person why). */
|
|
165
|
+
notOpened(title: string): string;
|
|
166
|
+
dirty(title: string): string;
|
|
167
|
+
notAddressable(title: string): string;
|
|
168
|
+
badAddress(): string;
|
|
169
|
+
cancelled(): string;
|
|
170
|
+
jumped(title: string): string;
|
|
171
|
+
}
|
|
172
|
+
/** The router (also the route sink places declare themselves to). */
|
|
173
|
+
export interface G9Router extends G9RouteSink {
|
|
174
|
+
readonly current: G9ReadableStore<G9Location>;
|
|
175
|
+
where(): G9Location;
|
|
176
|
+
go(address: string | G9Address, options?: G9GoOptions): Promise<G9GoResult>;
|
|
177
|
+
walk(address: string | G9Address, options?: G9WalkOptions): G9Walk;
|
|
178
|
+
snapshot(): G9Snapshot;
|
|
179
|
+
/** The snapshot with the scroll mark of every scroller on screen (on the last segment). */
|
|
180
|
+
snapshotWithScroll(): Promise<G9Snapshot>;
|
|
181
|
+
/** Puts a snapshot back (refused across another catalogue or past `maxAgeMs`, default unlimited). */
|
|
182
|
+
restore(snapshot: G9Snapshot, options?: G9GoOptions & {
|
|
183
|
+
readonly maxAgeMs?: number;
|
|
184
|
+
}): Promise<G9GoResult>;
|
|
185
|
+
excursion(address: string | G9Address, options?: G9GoOptions): Promise<G9Excursion>;
|
|
186
|
+
readonly history: G9ReadableStore<readonly G9TrailEntry[]>;
|
|
187
|
+
readonly busy: G9ReadableStore<boolean>;
|
|
188
|
+
/** The declaration of an open place (QA, the guide), or null. */
|
|
189
|
+
placeAt(index: number): G9PlaceDeclaration | null;
|
|
190
|
+
/** A new user / sign-out: the trail is forgotten and a running navigation ends. */
|
|
191
|
+
reset(): void;
|
|
192
|
+
/** The catalogue (manifests, links). */
|
|
193
|
+
readonly catalogue: G9Catalogue<unknown>;
|
|
194
|
+
}
|
|
195
|
+
/** True when a route sink is a full router. */
|
|
196
|
+
export declare function isG9Router(sink: G9RouteSink | null | undefined): sink is G9Router;
|
|
197
|
+
/** Creates a router. */
|
|
198
|
+
export declare function createG9Router<Ctx>(options: G9RouterOptions<Ctx>): G9Router;
|
|
199
|
+
/** The layers a declaration may use (re-exported for places outside the controls). */
|
|
200
|
+
export type { G9PlaceLayer };
|
|
201
|
+
//# sourceMappingURL=router.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"router.d.ts","sourceRoot":"","sources":["../../src/route/router.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,KAAK,SAAS,EACd,KAAK,WAAW,EAEhB,KAAK,WAAW,EAEhB,KAAK,kBAAkB,EAEvB,KAAK,YAAY,EACjB,KAAK,WAAW,EAEhB,KAAK,SAAS,EACd,KAAK,aAAa,EAClB,KAAK,UAAU,EACf,KAAK,aAAa,EASnB,MAAM,+BAA+B,CAAC;AAEvC,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AAS3D,6DAA6D;AAC7D,MAAM,WAAW,eAAe,CAAC,CAAC;IAChC,GAAG,IAAI,CAAC,CAAC;IACT,SAAS,CAAC,QAAQ,EAAE,MAAM,IAAI,GAAG,MAAM,IAAI,CAAC;CAC7C;AAED,iEAAiE;AACjE,MAAM,WAAW,UAAU;IACzB,+DAA+D;IAC/D,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IACxB,wCAAwC;IACxC,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,QAAQ,CAAC,QAAQ,EAAE,SAAS,SAAS,EAAE,CAAC;IACxC,yDAAyD;IACzD,QAAQ,CAAC,MAAM,EAAE,SAAS,MAAM,EAAE,CAAC;IACnC,+DAA+D;IAC/D,QAAQ,CAAC,UAAU,EAAE,OAAO,CAAC;IAC7B,iFAAiF;IACjF,QAAQ,CAAC,MAAM,EAAE,SAAS,MAAM,EAAE,CAAC;IACnC,kEAAkE;IAClE,QAAQ,CAAC,KAAK,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,GAAG,OAAO,GAAG,IAAI,CAAC,CAAC,CAAC;IAC3E,QAAQ,CAAC,QAAQ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