@azx-pbc/axiom-web 0.0.0-stage → 0.0.1
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 +21 -0
- package/README.md +161 -2
- package/dist/address.d.ts +32 -0
- package/dist/address.d.ts.map +1 -0
- package/dist/address.js +146 -0
- package/dist/address.js.map +1 -0
- package/dist/capture/MediaCapture.d.ts +45 -0
- package/dist/capture/MediaCapture.d.ts.map +1 -0
- package/dist/capture/MediaCapture.js +669 -0
- package/dist/capture/MediaCapture.js.map +1 -0
- package/dist/capture/SignatureCapture.d.ts +31 -0
- package/dist/capture/SignatureCapture.d.ts.map +1 -0
- package/dist/capture/SignatureCapture.js +329 -0
- package/dist/capture/SignatureCapture.js.map +1 -0
- package/dist/capture/copy.d.ts +101 -0
- package/dist/capture/copy.d.ts.map +1 -0
- package/dist/capture/copy.js +1369 -0
- package/dist/capture/copy.js.map +1 -0
- package/dist/capture/index.d.ts +19 -0
- package/dist/capture/index.d.ts.map +1 -0
- package/dist/capture/index.js +14 -0
- package/dist/capture/index.js.map +1 -0
- package/dist/capture/media-kind.d.ts +16 -0
- package/dist/capture/media-kind.d.ts.map +1 -0
- package/dist/capture/media-kind.js +64 -0
- package/dist/capture/media-kind.js.map +1 -0
- package/dist/capture/permissions.d.ts +109 -0
- package/dist/capture/permissions.d.ts.map +1 -0
- package/dist/capture/permissions.js +172 -0
- package/dist/capture/permissions.js.map +1 -0
- package/dist/capture/refusal.d.ts +13 -0
- package/dist/capture/refusal.d.ts.map +1 -0
- package/dist/capture/refusal.js +16 -0
- package/dist/capture/refusal.js.map +1 -0
- package/dist/controls.d.ts +64 -0
- package/dist/controls.d.ts.map +1 -0
- package/dist/controls.js +2524 -0
- package/dist/controls.js.map +1 -0
- package/dist/coordinate.d.ts +38 -0
- package/dist/coordinate.d.ts.map +1 -0
- package/dist/coordinate.js +220 -0
- package/dist/coordinate.js.map +1 -0
- package/dist/copy.d.ts +313 -0
- package/dist/copy.d.ts.map +1 -0
- package/dist/copy.js +2602 -0
- package/dist/copy.js.map +1 -0
- package/dist/countries.d.ts +14 -0
- package/dist/countries.d.ts.map +1 -0
- package/dist/countries.js +264 -0
- package/dist/countries.js.map +1 -0
- package/dist/format/calendar-locale.d.ts +19 -0
- package/dist/format/calendar-locale.d.ts.map +1 -0
- package/dist/format/calendar-locale.js +38 -0
- package/dist/format/calendar-locale.js.map +1 -0
- package/dist/format/country-names.d.ts +21 -0
- package/dist/format/country-names.d.ts.map +1 -0
- package/dist/format/country-names.js +2277 -0
- package/dist/format/country-names.js.map +1 -0
- package/dist/format/date.d.ts +58 -0
- package/dist/format/date.d.ts.map +1 -0
- package/dist/format/date.js +155 -0
- package/dist/format/date.js.map +1 -0
- package/dist/format/digits.d.ts +23 -0
- package/dist/format/digits.d.ts.map +1 -0
- package/dist/format/digits.js +46 -0
- package/dist/format/digits.js.map +1 -0
- package/dist/format/index.d.ts +28 -0
- package/dist/format/index.d.ts.map +1 -0
- package/dist/format/index.js +24 -0
- package/dist/format/index.js.map +1 -0
- package/dist/format/invariant.d.ts +8 -0
- package/dist/format/invariant.d.ts.map +1 -0
- package/dist/format/invariant.js +10 -0
- package/dist/format/invariant.js.map +1 -0
- package/dist/format/locale.d.ts +33 -0
- package/dist/format/locale.d.ts.map +1 -0
- package/dist/format/locale.js +39 -0
- package/dist/format/locale.js.map +1 -0
- package/dist/format/media-type.d.ts +8 -0
- package/dist/format/media-type.d.ts.map +1 -0
- package/dist/format/media-type.js +302 -0
- package/dist/format/media-type.js.map +1 -0
- package/dist/format/money.d.ts +52 -0
- package/dist/format/money.d.ts.map +1 -0
- package/dist/format/money.js +36 -0
- package/dist/format/money.js.map +1 -0
- package/dist/format/number.d.ts +28 -0
- package/dist/format/number.d.ts.map +1 -0
- package/dist/format/number.js +91 -0
- package/dist/format/number.js.map +1 -0
- package/dist/host.d.ts +122 -0
- package/dist/host.d.ts.map +1 -0
- package/dist/host.js +20 -0
- package/dist/host.js.map +1 -0
- package/dist/index.d.ts +57 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +49 -0
- package/dist/index.js.map +1 -0
- package/dist/media.d.ts +42 -0
- package/dist/media.d.ts.map +1 -0
- package/dist/media.js +151 -0
- package/dist/media.js.map +1 -0
- package/dist/pickers/DatePicker.d.ts +35 -0
- package/dist/pickers/DatePicker.d.ts.map +1 -0
- package/dist/pickers/DatePicker.js +212 -0
- package/dist/pickers/DatePicker.js.map +1 -0
- package/dist/pickers/TimeSegments.d.ts +27 -0
- package/dist/pickers/TimeSegments.d.ts.map +1 -0
- package/dist/pickers/TimeSegments.js +82 -0
- package/dist/pickers/TimeSegments.js.map +1 -0
- package/dist/pickers/day-picker-locale.d.ts +15 -0
- package/dist/pickers/day-picker-locale.d.ts.map +1 -0
- package/dist/pickers/day-picker-locale.js +46 -0
- package/dist/pickers/day-picker-locale.js.map +1 -0
- package/dist/render/dom.d.ts +100 -0
- package/dist/render/dom.d.ts.map +1 -0
- package/dist/render/dom.js +882 -0
- package/dist/render/dom.js.map +1 -0
- package/dist/render/layout.d.ts +45 -0
- package/dist/render/layout.d.ts.map +1 -0
- package/dist/render/layout.js +8 -0
- package/dist/render/layout.js.map +1 -0
- package/dist/schedule/SchedulePicker.d.ts +46 -0
- package/dist/schedule/SchedulePicker.d.ts.map +1 -0
- package/dist/schedule/SchedulePicker.js +160 -0
- package/dist/schedule/SchedulePicker.js.map +1 -0
- package/dist/schedule/timeslot.d.ts +52 -0
- package/dist/schedule/timeslot.d.ts.map +1 -0
- package/dist/schedule/timeslot.js +265 -0
- package/dist/schedule/timeslot.js.map +1 -0
- package/dist/styles.css +2151 -0
- package/dist/theme/index.d.ts +12 -0
- package/dist/theme/index.d.ts.map +1 -0
- package/dist/theme/index.js +11 -0
- package/dist/theme/index.js.map +1 -0
- package/dist/theme/presets.d.ts +93 -0
- package/dist/theme/presets.d.ts.map +1 -0
- package/dist/theme/presets.js +200 -0
- package/dist/theme/presets.js.map +1 -0
- package/dist/tokens.css +234 -0
- package/dist/wizard-checkpoints.d.ts +18 -0
- package/dist/wizard-checkpoints.d.ts.map +1 -0
- package/dist/wizard-checkpoints.js +56 -0
- package/dist/wizard-checkpoints.js.map +1 -0
- package/package.json +76 -3
|
@@ -0,0 +1,172 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Camera and microphone permission, as a state machine the capture panel can paint.
|
|
3
|
+
*
|
|
4
|
+
* A browser prompt is a decision the reader makes once per site, not a thing to ask for on
|
|
5
|
+
* mount. This module therefore exposes *requests* and outcomes rather than a provider: the panel
|
|
6
|
+
* calls `requestDevice` only from the reader's own button, the outcome is a tagged value that
|
|
7
|
+
* names what happened, and the session remembers a refusal so the next attempt shows guidance
|
|
8
|
+
* instead of prompting again. The media stream is returned to the caller, which owns its tracks;
|
|
9
|
+
* nothing here keeps one alive.
|
|
10
|
+
*
|
|
11
|
+
* The platform is a parameter, not a global read, so the same state machine is exercised in a
|
|
12
|
+
* browser, in jsdom, and in a Storybook story without a camera.
|
|
13
|
+
*/
|
|
14
|
+
import { mediaAcceptMatches } from '@azx-pbc/axiom-runtime';
|
|
15
|
+
/**
|
|
16
|
+
* The parameter-free, lower-case base media type (`audio/webm` from `audio/webm;codecs=opus`).
|
|
17
|
+
*
|
|
18
|
+
* `MediaRecorder` options accept codec parameters, while `mediaAcceptMatches` and the wire
|
|
19
|
+
* `MIME_TYPE_PATTERN` compare the base `type/subtype` alone.
|
|
20
|
+
*/
|
|
21
|
+
export function baseMimeType(mime) {
|
|
22
|
+
const semi = mime.indexOf(';');
|
|
23
|
+
return (semi === -1 ? mime : mime.slice(0, semi)).trim().toLowerCase();
|
|
24
|
+
}
|
|
25
|
+
export const RECORDER_CANDIDATES = {
|
|
26
|
+
audio: ['audio/webm;codecs=opus', 'audio/webm', 'audio/mp4', 'audio/ogg'],
|
|
27
|
+
video: ['video/webm;codecs=vp9', 'video/webm;codecs=vp8', 'video/webm', 'video/mp4'],
|
|
28
|
+
};
|
|
29
|
+
/** Whether `MediaRecorder.isTypeSupported` accepts one type, tolerating an absent class. */
|
|
30
|
+
function recorderSupports(type) {
|
|
31
|
+
try {
|
|
32
|
+
return typeof MediaRecorder !== 'undefined' && MediaRecorder.isTypeSupported(type);
|
|
33
|
+
}
|
|
34
|
+
catch {
|
|
35
|
+
return false;
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
/**
|
|
39
|
+
* The platform a browser offers, or a stand-in that reports no devices.
|
|
40
|
+
*
|
|
41
|
+
* The stand-in is never asked for a stream: `devices` is false, so the panel paints the insecure
|
|
42
|
+
* guidance and the file picker instead. That is the shape an old browser or a plain-http page
|
|
43
|
+
* gets, rather than a button that throws.
|
|
44
|
+
*/
|
|
45
|
+
export function browserCapturePlatform() {
|
|
46
|
+
const media = typeof navigator === 'undefined' ? undefined : navigator.mediaDevices;
|
|
47
|
+
const devices = media !== undefined && typeof media.getUserMedia === 'function';
|
|
48
|
+
return {
|
|
49
|
+
devices,
|
|
50
|
+
getUserMedia: (constraints) => {
|
|
51
|
+
if (media === undefined) {
|
|
52
|
+
return Promise.reject(new DOMException('mediaDevices is unavailable', 'NotSupportedError'));
|
|
53
|
+
}
|
|
54
|
+
return media.getUserMedia(constraints);
|
|
55
|
+
},
|
|
56
|
+
enumerateDevices: () => {
|
|
57
|
+
if (media === undefined)
|
|
58
|
+
return Promise.resolve([]);
|
|
59
|
+
return media.enumerateDevices();
|
|
60
|
+
},
|
|
61
|
+
recorderMime: (kind, accept) => RECORDER_CANDIDATES[kind].find((type) => recorderSupports(type) &&
|
|
62
|
+
(accept === undefined ||
|
|
63
|
+
accept.length === 0 ||
|
|
64
|
+
mediaAcceptMatches(accept, baseMimeType(type)))),
|
|
65
|
+
createRecorder: (stream, mimeType) => new MediaRecorder(stream, { mimeType }),
|
|
66
|
+
};
|
|
67
|
+
}
|
|
68
|
+
/** The constraints a request states for one device, and the camera it should prefer. */
|
|
69
|
+
export function constraintsFor(device, facing, withAudio) {
|
|
70
|
+
if (device === 'microphone')
|
|
71
|
+
return { audio: true, video: false };
|
|
72
|
+
return {
|
|
73
|
+
audio: withAudio,
|
|
74
|
+
video: { facingMode: { ideal: facing } },
|
|
75
|
+
};
|
|
76
|
+
}
|
|
77
|
+
/** The name of an error-shaped value, without trusting its prototype. */
|
|
78
|
+
function namedError(value) {
|
|
79
|
+
if (typeof value !== 'object' || value === null)
|
|
80
|
+
return { name: '' };
|
|
81
|
+
const name = Reflect.get(value, 'name');
|
|
82
|
+
return { name: typeof name === 'string' ? name : '' };
|
|
83
|
+
}
|
|
84
|
+
/**
|
|
85
|
+
* What a rejected `getUserMedia` means, by the DOMException name the browser states.
|
|
86
|
+
*
|
|
87
|
+
* A dismissal and a refusal are different facts — one closed the prompt unanswered, the other
|
|
88
|
+
* said no — and so are an absent device and a busy one. The mapping is the whole vocabulary the
|
|
89
|
+
* panel paints; an unknown name is an `error` whose sentence the panel writes, never the browser's
|
|
90
|
+
* engine text and never a silent "denied" that would send the reader to the wrong setting.
|
|
91
|
+
*/
|
|
92
|
+
export function classifyCaptureError(error) {
|
|
93
|
+
const { name } = namedError(error);
|
|
94
|
+
switch (name) {
|
|
95
|
+
case 'NotAllowedError':
|
|
96
|
+
case 'PermissionDeniedError':
|
|
97
|
+
return { kind: 'denied' };
|
|
98
|
+
case 'AbortError':
|
|
99
|
+
return { kind: 'dismissed' };
|
|
100
|
+
case 'NotFoundError':
|
|
101
|
+
case 'DevicesNotFoundError':
|
|
102
|
+
case 'OverconstrainedError':
|
|
103
|
+
return { kind: 'missing' };
|
|
104
|
+
case 'NotReadableError':
|
|
105
|
+
case 'TrackStartError':
|
|
106
|
+
return { kind: 'busy' };
|
|
107
|
+
case 'SecurityError':
|
|
108
|
+
case 'TypeError':
|
|
109
|
+
return { kind: 'insecure' };
|
|
110
|
+
case 'NotSupportedError':
|
|
111
|
+
return { kind: 'unsupported' };
|
|
112
|
+
default:
|
|
113
|
+
return { kind: 'error' };
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
/** Ask one device for a stream. The caller owns the tracks and must stop them. */
|
|
117
|
+
export async function requestDevice(platform, device, facing, withAudio) {
|
|
118
|
+
if (!platform.devices)
|
|
119
|
+
return { kind: 'insecure' };
|
|
120
|
+
try {
|
|
121
|
+
const stream = await platform.getUserMedia(constraintsFor(device, facing, withAudio));
|
|
122
|
+
return { kind: 'granted', stream };
|
|
123
|
+
}
|
|
124
|
+
catch (error) {
|
|
125
|
+
return classifyCaptureError(error);
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
/**
|
|
129
|
+
* What this browser session has already decided about one device.
|
|
130
|
+
*
|
|
131
|
+
* The map is the session's memory, not a permission cache: it records only the answer the reader
|
|
132
|
+
* already gave, so a denial shows guidance and an explicit "Ask again" instead of making every
|
|
133
|
+
* capture button prompt. `granted` is remembered too, but a stream is still requested per use —
|
|
134
|
+
* permission is not a stream, and the tracks must be stopped when the panel closes.
|
|
135
|
+
*/
|
|
136
|
+
const remembered = new Map();
|
|
137
|
+
/** The last outcome this session saw for a device, if any. */
|
|
138
|
+
export function rememberedCaptureOutcome(device) {
|
|
139
|
+
return remembered.get(device);
|
|
140
|
+
}
|
|
141
|
+
/** Record one outcome for the rest of the session. */
|
|
142
|
+
export function rememberCaptureOutcome(device, kind) {
|
|
143
|
+
remembered.set(device, kind);
|
|
144
|
+
}
|
|
145
|
+
/** Forget the session's answer so the next request may prompt again. */
|
|
146
|
+
export function forgetCaptureOutcome(device) {
|
|
147
|
+
remembered.delete(device);
|
|
148
|
+
}
|
|
149
|
+
/** Stop every track of a stream, tolerating one that is already stopped or absent. */
|
|
150
|
+
export function stopStream(stream) {
|
|
151
|
+
if (stream === undefined)
|
|
152
|
+
return;
|
|
153
|
+
for (const track of stream.getTracks()) {
|
|
154
|
+
try {
|
|
155
|
+
track.stop();
|
|
156
|
+
}
|
|
157
|
+
catch {
|
|
158
|
+
// A track that is already ended is the state this function exists to reach.
|
|
159
|
+
}
|
|
160
|
+
}
|
|
161
|
+
}
|
|
162
|
+
/** The number of video inputs the platform reports, for the camera-switch affordance. */
|
|
163
|
+
export async function cameraCount(platform) {
|
|
164
|
+
try {
|
|
165
|
+
const devices = await platform.enumerateDevices();
|
|
166
|
+
return devices.filter((device) => device.kind === 'videoinput').length;
|
|
167
|
+
}
|
|
168
|
+
catch {
|
|
169
|
+
return 0;
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
//# sourceMappingURL=permissions.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"permissions.js","sourceRoot":"","sources":["../../src/capture/permissions.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAEH,OAAO,EAAE,kBAAkB,EAAE,MAAM,wBAAwB,CAAC;AA6D5D;;;;;GAKG;AACH,MAAM,UAAU,YAAY,CAAC,IAAY;IACvC,MAAM,IAAI,GAAG,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC;IAC/B,OAAO,CAAC,IAAI,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,EAAE,IAAI,CAAC,CAAC,CAAC,IAAI,EAAE,CAAC,WAAW,EAAE,CAAC;AACzE,CAAC;AAED,MAAM,CAAC,MAAM,mBAAmB,GAA2D;IACzF,KAAK,EAAE,CAAC,wBAAwB,EAAE,YAAY,EAAE,WAAW,EAAE,WAAW,CAAC;IACzE,KAAK,EAAE,CAAC,uBAAuB,EAAE,uBAAuB,EAAE,YAAY,EAAE,WAAW,CAAC;CACrF,CAAC;AAEF,4FAA4F;AAC5F,SAAS,gBAAgB,CAAC,IAAY;IACpC,IAAI,CAAC;QACH,OAAO,OAAO,aAAa,KAAK,WAAW,IAAI,aAAa,CAAC,eAAe,CAAC,IAAI,CAAC,CAAC;IACrF,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,KAAK,CAAC;IACf,CAAC;AACH,CAAC;AAED;;;;;;GAMG;AACH,MAAM,UAAU,sBAAsB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,CAAC;QAAC,MAAM,CAAC;YACP,4EAA4E;QAC9E,CAAC;IACH,CAAC;AACH,CAAC;AAED,yFAAyF;AACzF,MAAM,CAAC,KAAK,UAAU,WAAW,CAAC,QAAyB;IACzD,IAAI,CAAC;QACH,MAAM,OAAO,GAAG,MAAM,QAAQ,CAAC,gBAAgB,EAAE,CAAC;QAClD,OAAO,OAAO,CAAC,MAAM,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,MAAM,CAAC,IAAI,KAAK,YAAY,CAAC,CAAC,MAAM,CAAC;IACzE,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,CAAC,CAAC;IACX,CAAC;AACH,CAAC","sourcesContent":["/**\n * Camera and microphone permission, as a state machine the capture panel can paint.\n *\n * A browser prompt is a decision the reader makes once per site, not a thing to ask for on\n * mount. This module therefore exposes *requests* and outcomes rather than a provider: the panel\n * calls `requestDevice` only from the reader's own button, the outcome is a tagged value that\n * names what happened, and the session remembers a refusal so the next attempt shows guidance\n * instead of prompting again. The media stream is returned to the caller, which owns its tracks;\n * nothing here keeps one alive.\n *\n * The platform is a parameter, not a global read, so the same state machine is exercised in a\n * browser, in jsdom, and in a Storybook story without a camera.\n */\n\nimport { mediaAcceptMatches } from '@azx-pbc/axiom-runtime';\n\n/** The two device kinds a capture panel can ask for. */\nexport type CaptureDevice = 'camera' | 'microphone';\n\n/** The outcomes a request can end in, one tag each. */\nexport type CapturePermissionKind =\n | 'granted'\n | 'denied'\n | 'dismissed'\n | 'missing'\n | 'busy'\n | 'insecure'\n | 'unsupported'\n | 'error';\n\n/** What one permission request answered. */\nexport type CapturePermission =\n | { readonly kind: 'granted'; readonly stream: MediaStream }\n | { readonly kind: 'denied' }\n | { readonly kind: 'dismissed' }\n | { readonly kind: 'missing' }\n | { readonly kind: 'busy' }\n | { readonly kind: 'insecure' }\n | { readonly kind: 'unsupported' }\n /**\n * A request that failed for a cause the browser did not name.\n *\n * The browser's own `message` is engine text, not a sentence a respondent can act on, and it\n * often repeats the sentence the panel would wrap it in. The panel states its own sentence for\n * this case, so no detail travels here.\n */\n | { readonly kind: 'error' };\n\n/**\n * The slice of `MediaRecorder` the panel uses.\n *\n * Declared structurally so a fake recorder can stand at this platform boundary in tests and in a\n * review story; the browser's own class satisfies it as written.\n */\nexport interface CaptureRecorder {\n readonly mimeType: string;\n readonly state: 'inactive' | 'recording' | 'paused';\n ondataavailable: ((event: BlobEvent) => void) | null;\n onstop: ((event: Event) => void) | null;\n onerror: ((event: ErrorEvent) => void) | null;\n start(timeslice?: number): void;\n stop(): void;\n}\n\n/** The browser facilities a capture panel needs, injectable as one object. */\nexport interface CapturePlatform {\n /** Whether `getUserMedia` is reachable at all (a secure context with the API). */\n readonly devices: boolean;\n getUserMedia(constraints: MediaStreamConstraints): Promise<MediaStream>;\n enumerateDevices(): Promise<readonly MediaDeviceInfo[]>;\n /** The first media-recorder type this browser supports for a kind and optional `accept` list. */\n recorderMime(kind: 'audio' | 'video', accept?: readonly string[]): string | undefined;\n createRecorder(stream: MediaStream, mimeType: string): CaptureRecorder;\n}\n\n/**\n * The parameter-free, lower-case base media type (`audio/webm` from `audio/webm;codecs=opus`).\n *\n * `MediaRecorder` options accept codec parameters, while `mediaAcceptMatches` and the wire\n * `MIME_TYPE_PATTERN` compare the base `type/subtype` alone.\n */\nexport function baseMimeType(mime: string): string {\n const semi = mime.indexOf(';');\n return (semi === -1 ? mime : mime.slice(0, semi)).trim().toLowerCase();\n}\n\nexport const RECORDER_CANDIDATES: Readonly<Record<'audio' | 'video', readonly string[]>> = {\n audio: ['audio/webm;codecs=opus', 'audio/webm', 'audio/mp4', 'audio/ogg'],\n video: ['video/webm;codecs=vp9', 'video/webm;codecs=vp8', 'video/webm', 'video/mp4'],\n};\n\n/** Whether `MediaRecorder.isTypeSupported` accepts one type, tolerating an absent class. */\nfunction recorderSupports(type: string): boolean {\n try {\n return typeof MediaRecorder !== 'undefined' && MediaRecorder.isTypeSupported(type);\n } catch {\n return false;\n }\n}\n\n/**\n * The platform a browser offers, or a stand-in that reports no devices.\n *\n * The stand-in is never asked for a stream: `devices` is false, so the panel paints the insecure\n * guidance and the file picker instead. That is the shape an old browser or a plain-http page\n * gets, rather than a button that throws.\n */\nexport function browserCapturePlatform(): CapturePlatform {\n const media = typeof navigator === 'undefined' ? undefined : navigator.mediaDevices;\n const devices = media !== undefined && typeof media.getUserMedia === 'function';\n return {\n devices,\n getUserMedia: (constraints) => {\n if (media === undefined) {\n return Promise.reject(new DOMException('mediaDevices is unavailable', 'NotSupportedError'));\n }\n return media.getUserMedia(constraints);\n },\n enumerateDevices: () => {\n if (media === undefined) return Promise.resolve([]);\n return media.enumerateDevices();\n },\n recorderMime: (kind, accept) =>\n RECORDER_CANDIDATES[kind].find(\n (type) =>\n recorderSupports(type) &&\n (accept === undefined ||\n accept.length === 0 ||\n mediaAcceptMatches(accept, baseMimeType(type))),\n ),\n createRecorder: (stream, mimeType) => new MediaRecorder(stream, { mimeType }),\n };\n}\n\n/** The constraints a request states for one device, and the camera it should prefer. */\nexport function constraintsFor(\n device: CaptureDevice,\n facing: 'environment' | 'user',\n withAudio: boolean,\n): MediaStreamConstraints {\n if (device === 'microphone') return { audio: true, video: false };\n return {\n audio: withAudio,\n video: { facingMode: { ideal: facing } },\n };\n}\n\n/** The name of an error-shaped value, without trusting its prototype. */\nfunction namedError(value: unknown): { readonly name: string } {\n if (typeof value !== 'object' || value === null) return { name: '' };\n const name = Reflect.get(value, 'name');\n return { name: typeof name === 'string' ? name : '' };\n}\n\n/**\n * What a rejected `getUserMedia` means, by the DOMException name the browser states.\n *\n * A dismissal and a refusal are different facts — one closed the prompt unanswered, the other\n * said no — and so are an absent device and a busy one. The mapping is the whole vocabulary the\n * panel paints; an unknown name is an `error` whose sentence the panel writes, never the browser's\n * engine text and never a silent \"denied\" that would send the reader to the wrong setting.\n */\nexport function classifyCaptureError(error: unknown): CapturePermission {\n const { name } = namedError(error);\n switch (name) {\n case 'NotAllowedError':\n case 'PermissionDeniedError':\n return { kind: 'denied' };\n case 'AbortError':\n return { kind: 'dismissed' };\n case 'NotFoundError':\n case 'DevicesNotFoundError':\n case 'OverconstrainedError':\n return { kind: 'missing' };\n case 'NotReadableError':\n case 'TrackStartError':\n return { kind: 'busy' };\n case 'SecurityError':\n case 'TypeError':\n return { kind: 'insecure' };\n case 'NotSupportedError':\n return { kind: 'unsupported' };\n default:\n return { kind: 'error' };\n }\n}\n\n/** Ask one device for a stream. The caller owns the tracks and must stop them. */\nexport async function requestDevice(\n platform: CapturePlatform,\n device: CaptureDevice,\n facing: 'environment' | 'user',\n withAudio: boolean,\n): Promise<CapturePermission> {\n if (!platform.devices) return { kind: 'insecure' };\n try {\n const stream = await platform.getUserMedia(constraintsFor(device, facing, withAudio));\n return { kind: 'granted', stream };\n } catch (error) {\n return classifyCaptureError(error);\n }\n}\n\n/**\n * What this browser session has already decided about one device.\n *\n * The map is the session's memory, not a permission cache: it records only the answer the reader\n * already gave, so a denial shows guidance and an explicit \"Ask again\" instead of making every\n * capture button prompt. `granted` is remembered too, but a stream is still requested per use —\n * permission is not a stream, and the tracks must be stopped when the panel closes.\n */\nconst remembered = new Map<CaptureDevice, CapturePermissionKind>();\n\n/** The last outcome this session saw for a device, if any. */\nexport function rememberedCaptureOutcome(device: CaptureDevice): CapturePermissionKind | undefined {\n return remembered.get(device);\n}\n\n/** Record one outcome for the rest of the session. */\nexport function rememberCaptureOutcome(device: CaptureDevice, kind: CapturePermissionKind): void {\n remembered.set(device, kind);\n}\n\n/** Forget the session's answer so the next request may prompt again. */\nexport function forgetCaptureOutcome(device: CaptureDevice): void {\n remembered.delete(device);\n}\n\n/** Stop every track of a stream, tolerating one that is already stopped or absent. */\nexport function stopStream(stream: MediaStream | undefined): void {\n if (stream === undefined) return;\n for (const track of stream.getTracks()) {\n try {\n track.stop();\n } catch {\n // A track that is already ended is the state this function exists to reach.\n }\n }\n}\n\n/** The number of video inputs the platform reports, for the camera-switch affordance. */\nexport async function cameraCount(platform: CapturePlatform): Promise<number> {\n try {\n const devices = await platform.enumerateDevices();\n return devices.filter((device) => device.kind === 'videoinput').length;\n } catch {\n return 0;\n }\n}\n"]}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* A refusal a capture action already understands, thrown as a plain sentence.
|
|
3
|
+
*
|
|
4
|
+
* A host that opens a picker knows why a file was rejected before it has bytes to store — the
|
|
5
|
+
* declared `accept` list and byte bounds are in hand. Returning `undefined` would look like a
|
|
6
|
+
* cancellation, and a bare `Error` would be painted as the store's failure with its status code
|
|
7
|
+
* suppressed. This error is the third answer: the adapter paints its message as the detail of the
|
|
8
|
+
* catalogue's "could not be attached" sentence.
|
|
9
|
+
*/
|
|
10
|
+
export declare class CaptureRefusedError extends Error {
|
|
11
|
+
constructor(detail: string);
|
|
12
|
+
}
|
|
13
|
+
//# sourceMappingURL=refusal.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"refusal.d.ts","sourceRoot":"","sources":["../../src/capture/refusal.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AACH,qBAAa,mBAAoB,SAAQ,KAAK;IAC5C,YAAmB,MAAM,EAAE,MAAM,EAGhC;CACF"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* A refusal a capture action already understands, thrown as a plain sentence.
|
|
3
|
+
*
|
|
4
|
+
* A host that opens a picker knows why a file was rejected before it has bytes to store — the
|
|
5
|
+
* declared `accept` list and byte bounds are in hand. Returning `undefined` would look like a
|
|
6
|
+
* cancellation, and a bare `Error` would be painted as the store's failure with its status code
|
|
7
|
+
* suppressed. This error is the third answer: the adapter paints its message as the detail of the
|
|
8
|
+
* catalogue's "could not be attached" sentence.
|
|
9
|
+
*/
|
|
10
|
+
export class CaptureRefusedError extends Error {
|
|
11
|
+
constructor(detail) {
|
|
12
|
+
super(detail);
|
|
13
|
+
this.name = 'AxiomCaptureRefused';
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
//# sourceMappingURL=refusal.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"refusal.js","sourceRoot":"","sources":["../../src/capture/refusal.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AACH,MAAM,OAAO,mBAAoB,SAAQ,KAAK;IAC5C,YAAmB,MAAc;QAC/B,KAAK,CAAC,MAAM,CAAC,CAAC;QACd,IAAI,CAAC,IAAI,GAAG,qBAAqB,CAAC;IACpC,CAAC;CACF","sourcesContent":["/**\n * A refusal a capture action already understands, thrown as a plain sentence.\n *\n * A host that opens a picker knows why a file was rejected before it has bytes to store — the\n * declared `accept` list and byte bounds are in hand. Returning `undefined` would look like a\n * cancellation, and a bare `Error` would be painted as the store's failure with its status code\n * suppressed. This error is the third answer: the adapter paints its message as the detail of the\n * catalogue's \"could not be attached\" sentence.\n */\nexport class CaptureRefusedError extends Error {\n public constructor(detail: string) {\n super(detail);\n this.name = 'AxiomCaptureRefused';\n }\n}\n"]}
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
import type { FieldError, FieldProps, RenderControlNode, RenderTranslate } from '@azx-pbc/axiom-react';
|
|
2
|
+
import type { Control, FieldOption, WireValue } from '@azx-pbc/axiom-runtime';
|
|
3
|
+
import type { Context, ReactElement } from 'react';
|
|
4
|
+
/**
|
|
5
|
+
* One control, painted from its declaration.
|
|
6
|
+
*
|
|
7
|
+
* The declared control decides which native affordance appears, and nothing here knows which
|
|
8
|
+
* document it is painting. A control whose value the host cannot write from the domain it holds
|
|
9
|
+
* — a media reference, a timeslot with no host loader — is shown read-only rather than as a text
|
|
10
|
+
* box that would write a value the wire contract refuses. A captured signature is read-only too,
|
|
11
|
+
* with the host's own sign action beside it when the page has a signer: the record it signs is the
|
|
12
|
+
* one the page shows, so a branch the page excluded is not in the signing.
|
|
13
|
+
*
|
|
14
|
+
* An address and a coordinate are edited as their declared records rather than as text: the
|
|
15
|
+
* address editor writes only a complete shape, and the coordinate editor offers the host's
|
|
16
|
+
* capture beside manual decimal entries so a denied or offline reader is never left without a
|
|
17
|
+
* path to answer.
|
|
18
|
+
*/
|
|
19
|
+
/** The presentation hints a compiled field carries for a host component. */
|
|
20
|
+
export interface ControlConstraints {
|
|
21
|
+
readonly minimum: number | string | undefined;
|
|
22
|
+
readonly maximum: number | string | undefined;
|
|
23
|
+
readonly step: number | string | undefined;
|
|
24
|
+
readonly units: readonly string[] | undefined;
|
|
25
|
+
readonly accept: readonly string[] | undefined;
|
|
26
|
+
readonly minBytes: number | undefined;
|
|
27
|
+
readonly maxBytes: number | undefined;
|
|
28
|
+
readonly scale: number | undefined;
|
|
29
|
+
readonly currency: string | undefined;
|
|
30
|
+
}
|
|
31
|
+
/** The controlled props every custom control slot receives. */
|
|
32
|
+
export interface ControlComponentProps {
|
|
33
|
+
readonly controlId: string;
|
|
34
|
+
readonly descriptionId: string | undefined;
|
|
35
|
+
readonly errorId: string;
|
|
36
|
+
readonly field: FieldProps;
|
|
37
|
+
readonly value: WireValue | undefined;
|
|
38
|
+
readonly setValue: (value: WireValue) => void;
|
|
39
|
+
/**
|
|
40
|
+
* Non-throwing write path: returns the engine outcome (`committed` or `refused`) instead of
|
|
41
|
+
* throwing `WriteRefusedError`, so a custom control can inspect and display expected refusals.
|
|
42
|
+
*/
|
|
43
|
+
readonly trySetValue: NonNullable<FieldProps['trySetValue']>;
|
|
44
|
+
readonly error: FieldError | undefined;
|
|
45
|
+
readonly required: boolean;
|
|
46
|
+
readonly disabled: boolean;
|
|
47
|
+
readonly readOnly: boolean;
|
|
48
|
+
readonly mayWrite: boolean;
|
|
49
|
+
readonly locale: string | undefined;
|
|
50
|
+
readonly options: readonly FieldOption[] | undefined;
|
|
51
|
+
readonly constraints: ControlConstraints;
|
|
52
|
+
}
|
|
53
|
+
/** A host component that replaces one default control entry. */
|
|
54
|
+
export type ControlComponent = (props: ControlComponentProps) => ReactElement | null;
|
|
55
|
+
/** The slot map a host supplies to `RenderedForm` / `LayoutTree`. */
|
|
56
|
+
export type ControlComponents = Partial<Record<Control | 'signature' | 'media', ControlComponent>>;
|
|
57
|
+
/** The map in force for the tree; absent means every control uses the adapter's default. */
|
|
58
|
+
export declare const ControlComponentsContext: Context<ControlComponents | undefined>;
|
|
59
|
+
export declare function Control({ node, rowKey, translate, }: {
|
|
60
|
+
readonly node: RenderControlNode;
|
|
61
|
+
readonly rowKey?: string | number;
|
|
62
|
+
readonly translate: RenderTranslate;
|
|
63
|
+
}): ReactElement;
|
|
64
|
+
//# sourceMappingURL=controls.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"controls.d.ts","sourceRoot":"","sources":["../src/controls.tsx"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAIV,UAAU,EACV,UAAU,EACV,iBAAiB,EACjB,eAAe,EAChB,MAAM,sBAAsB,CAAC;AAU9B,OAAO,KAAK,EACV,OAAO,EACP,WAAW,EAIX,SAAS,EACV,MAAM,wBAAwB,CAAC;AAEhC,OAAO,KAAK,EAAe,OAAO,EAAiB,YAAY,EAAE,MAAM,OAAO,CAAC;AAyB/E;;;;;;;;;;;;;;GAcG;AAEH,4EAA4E;AAC5E,MAAM,WAAW,kBAAkB;IACjC,QAAQ,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS,CAAC;IAC9C,QAAQ,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS,CAAC;IAC9C,QAAQ,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS,CAAC;IAC3C,QAAQ,CAAC,KAAK,EAAE,SAAS,MAAM,EAAE,GAAG,SAAS,CAAC;IAC9C,QAAQ,CAAC,MAAM,EAAE,SAAS,MAAM,EAAE,GAAG,SAAS,CAAC;IAC/C,QAAQ,CAAC,QAAQ,EAAE,MAAM,GAAG,SAAS,CAAC;IACtC,QAAQ,CAAC,QAAQ,EAAE,MAAM,GAAG,SAAS,CAAC;IACtC,QAAQ,CAAC,KAAK,EAAE,MAAM,GA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