@g9tm/lynxcontrols-barcode 0.0.0-stage → 1.4.2
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/README.md +47 -2
- package/dist/.tsbuildinfo +1 -0
- package/dist/barcode-text-entry.d.ts +54 -0
- package/dist/barcode-text-entry.d.ts.map +1 -0
- package/dist/barcode-text-entry.jsx +177 -0
- package/dist/barcode-text-entry.jsx.map +1 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.jsx +2 -0
- package/dist/model.d.ts +43 -0
- package/dist/model.d.ts.map +1 -0
- package/dist/model.jsx +32 -0
- package/dist/model.jsx.map +1 -0
- package/package.json +29 -4
package/README.md
CHANGED
|
@@ -1,3 +1,48 @@
|
|
|
1
|
-
#
|
|
1
|
+
# @g9tm/lynxcontrols-barcode
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
`G9BarcodeTextEntry`: a scanner-aware text field (MAUI `G9MAUIControls.Barcode`). The camera is never this package's:
|
|
4
|
+
handle `onScanRequested` and drive your own scanner, or supply `services.scanner` and the field drives it. Depends on
|
|
5
|
+
`@g9tm/lynxcontrols-foundation` and `@g9tm/lynxcontrols` only; importing `@g9tm/lynxcontrols` never pulls it in. Migration table:
|
|
6
|
+
[`docs/migration/Barcode.Controls.md`](docs/migration/Barcode.Controls.md).
|
|
7
|
+
|
|
8
|
+
```tsx
|
|
9
|
+
import { G9BarcodeTextEntry, type G9BarcodeTextEntryHandle } from '@g9tm/lynxcontrols-barcode';
|
|
10
|
+
|
|
11
|
+
// A: you own the camera (MAUI ScanRequested)
|
|
12
|
+
const field = useRef<G9BarcodeTextEntryHandle | null>(null);
|
|
13
|
+
<G9BarcodeTextEntry
|
|
14
|
+
ref={field}
|
|
15
|
+
label="Sample code"
|
|
16
|
+
acceptedCodeRegex="^\\d{3}/\\d{3}/\\d{6}$"
|
|
17
|
+
onScanRequested={async () => {
|
|
18
|
+
field.current?.startScan();
|
|
19
|
+
try {
|
|
20
|
+
field.current?.acceptScannedCode(await myScanner.scanOnce());
|
|
21
|
+
} finally {
|
|
22
|
+
field.current?.stopScan();
|
|
23
|
+
}
|
|
24
|
+
}}
|
|
25
|
+
onAccepted={(code) => model.add(code)}
|
|
26
|
+
/>
|
|
27
|
+
|
|
28
|
+
// B: services.scanner ({ isAvailable, scan }) does it: a tap scans; 'multiple' stays armed until cancelled
|
|
29
|
+
<G9BarcodeTextEntry label="Scanned items" scanMode="multiple" isEditable scanFormats={['code128']} />
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
## Behaviour
|
|
33
|
+
|
|
34
|
+
- **States** `idle` → `scanBusy` (spinner, read-only, `scanBusyText` as placeholder) → `accepted` (success outline,
|
|
35
|
+
✓) or `error` (error outline, ⓘ). The state is layered over your own `hasError`, `readOnly`, `useStatusColor`,
|
|
36
|
+
`statusColor`, `placeholder` and `trailingIcon`; they come back when the state no longer needs them. Typing after a
|
|
37
|
+
result returns the field to `idle`. `scanState` is controllable.
|
|
38
|
+
- **Accepting.** `acceptedCodeRegex` takes a pattern string, a `RegExp` or a function. A malformed pattern or a
|
|
39
|
+
throwing function rejects the code instead of throwing into the scan flow. Codes over 4096 characters are rejected
|
|
40
|
+
before any pattern runs (MAUI bounded the match with a 250 ms regex timeout, which JavaScript cannot do).
|
|
41
|
+
`'single'` replaces the text; `'multiple'` appends `", code"`. `onAccepted` never fires for typed text.
|
|
42
|
+
- **Scanner service.** Without `onScanRequested`, the scan icon is shown only when `services.scanner.isAvailable()`
|
|
43
|
+
resolves true. A scan runs with an abort signal: `stopScan()` and unmount abort it and a late result is ignored;
|
|
44
|
+
`cancelled` returns to `idle`, `denied` and failures become `error` (failures also go to diagnostics).
|
|
45
|
+
- **Layout.** The scan icon is pinned to the physical right and the text is pinned LTR in RTL pages (barcodes are
|
|
46
|
+
left-to-right symbol strings); the label and outline follow the page direction.
|
|
47
|
+
|
|
48
|
+
Real scanner integration is a device check (`plan/execution/Native-Validation-Pending.md` N-045).
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"fileNames":["../../../node_modules/typescript/lib/lib.es5.d.ts","../../../node_modules/typescript/lib/lib.es2015.d.ts","../../../node_modules/typescript/lib/lib.es2016.d.ts","../../../node_modules/typescript/lib/lib.es2017.d.ts","../../../node_modules/typescript/lib/lib.es2018.d.ts","../../../node_modules/typescript/lib/lib.es2019.d.ts","../../../node_modules/typescript/lib/lib.dom.d.ts","../../../node_modules/typescript/lib/lib.es2015.core.d.ts","../../../node_modules/typescript/lib/lib.es2015.collection.d.ts","../../../node_modules/typescript/lib/lib.es2015.generator.d.ts","../../../node_modules/typescript/lib/lib.es2015.iterable.d.ts","../../../node_modules/typescript/lib/lib.es2015.promise.d.ts","../../../node_modules/typescript/lib/lib.es2015.proxy.d.ts","../../../node_modules/typescript/lib/lib.es2015.reflect.d.ts","../../../node_modules/typescript/lib/lib.es2015.symbol.d.ts","../../../node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts","../../../node_modules/typescript/lib/lib.es2016.array.include.d.ts","../../../node_modules/typescript/lib/lib.es2016.intl.d.ts","../../../node_modules/typescript/lib/lib.es2017.arraybuffer.d.ts","../../../node_modules/typescript/lib/lib.es2017.date.d.ts","../../../node_modules/typescript/lib/lib.es2017.object.d.ts","../../../node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts","../../../node_modules/typescript/lib/lib.es2017.string.d.ts","../../../node_modules/typescript/lib/lib.es2017.intl.d.ts","../../../node_modules/typescript/lib/lib.es2017.typedarrays.d.ts","../../../node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts","../../../node_modules/typescript/lib/lib.es2018.asynciterable.d.ts","../../../node_modules/typescript/lib/lib.es2018.intl.d.ts","../../../node_modules/typescript/lib/lib.es2018.promise.d.ts","../../../node_modules/typescript/lib/lib.es2018.regexp.d.ts","../../../node_modules/typescript/lib/lib.es2019.array.d.ts","../../../node_modules/typescript/lib/lib.es2019.object.d.ts","../../../node_modules/typescript/lib/lib.es2019.string.d.ts","../../../node_modules/typescript/lib/lib.es2019.symbol.d.ts","../../../node_modules/typescript/lib/lib.es2019.intl.d.ts","../../../node_modules/typescript/lib/lib.decorators.d.ts","../../../node_modules/typescript/lib/lib.decorators.legacy.d.ts","../../../node_modules/@types/react/global.d.ts","../../../node_modules/@types/react/node_modules/csstype/index.d.ts","../../../node_modules/@types/prop-types/index.d.ts","../../../node_modules/@types/react/index.d.ts","../../../node_modules/@lynx-js/types/types/background-thread/animation.d.ts","../../../node_modules/csstype/index.d.ts","../../../node_modules/@lynx-js/types/types/common/csstype.d.ts","../../../node_modules/@lynx-js/types/types/main-thread/animation.d.ts","../../../node_modules/@lynx-js/types/types/main-thread/element.d.ts","../../../node_modules/@lynx-js/types/types/common/events.d.ts","../../../node_modules/@lynx-js/types/types/common/system-info.d.ts","../../../node_modules/@lynx-js/types/types/common/performance.d.ts","../../../node_modules/@lynx-js/types/types/main-thread/lynx.d.ts","../../../node_modules/@lynx-js/types/types/main-thread/events.d.ts","../../../node_modules/@lynx-js/types/types/main-thread/index.d.ts","../../../node_modules/@lynx-js/types/types/common/lynx.d.ts","../../../node_modules/@lynx-js/types/types/common/global.d.ts","../../../node_modules/@lynx-js/types/types/common/props.d.ts","../../../node_modules/@lynx-js/types/types/common/element/component.d.ts","../../../node_modules/@lynx-js/types/types/common/element/filter-image.d.ts","../../../node_modules/@lynx-js/types/types/common/element/image.d.ts","../../../node_modules/@lynx-js/types/types/common/element/common.d.ts","../../../node_modules/@lynx-js/types/types/common/element/list.d.ts","../../../node_modules/@lynx-js/types/types/common/element/list-item.d.ts","../../../node_modules/@lynx-js/types/types/common/element/page.d.ts","../../../node_modules/@lynx-js/types/types/common/element/scroll-view.d.ts","../../../node_modules/@lynx-js/types/types/common/element/text.d.ts","../../../node_modules/@lynx-js/types/types/common/element/view.d.ts","../../../node_modules/@lynx-js/types/types/common/element/input.d.ts","../../../node_modules/@lynx-js/types/types/common/element/textarea.d.ts","../../../node_modules/@lynx-js/types/types/common/element/title-bar-view.d.ts","../../../node_modules/@lynx-js/types/types/common/element/svg.d.ts","../../../node_modules/@lynx-js/types/types/common/element/refresh.d.ts","../../../node_modules/@lynx-js/types/types/common/element/scroll-coordinator.d.ts","../../../node_modules/@lynx-js/types/types/common/element/viewpager.d.ts","../../../node_modules/@lynx-js/types/types/common/element/blur-view.d.ts","../../../node_modules/@lynx-js/types/types/common/element/webview.d.ts","../../../node_modules/@lynx-js/types/types/common/element/markdown.d.ts","../../../node_modules/@lynx-js/types/types/common/element/video.d.ts","../../../node_modules/@lynx-js/types/types/background-thread/lynx-performance-entry.d.ts","../../../node_modules/@lynx-js/types/types/common/element/frame.d.ts","../../../node_modules/@lynx-js/types/types/common/element/overlay.d.ts","../../../node_modules/@lynx-js/types/types/common/element/element.d.ts","../../../node_modules/@lynx-js/types/types/common/element/methods.d.ts","../../../node_modules/@lynx-js/types/types/common/element/attributes.d.ts","../../../node_modules/@lynx-js/types/types/common/element/index.d.ts","../../../node_modules/@lynx-js/types/types/common/console.d.ts","../../../node_modules/@lynx-js/types/types/common/index.d.ts","../../../node_modules/@lynx-js/types/types/background-thread/event.d.ts","../../../node_modules/@lynx-js/types/types/background-thread/nodes-ref.d.ts","../../../node_modules/@lynx-js/types/types/background-thread/app.d.ts","../../../node_modules/@lynx-js/types/types/background-thread/performance.d.ts","../../../node_modules/@lynx-js/types/types/background-thread/fetch.d.ts","../../../node_modules/@lynx-js/types/types/background-thread/lynx.d.ts","../../../node_modules/@lynx-js/types/types/background-thread/native-modules.d.ts","../../../node_modules/@lynx-js/types/types/background-thread/text-encoder-decoder.d.ts","../../../node_modules/@lynx-js/types/types/background-thread/index.d.ts","../../../node_modules/@lynx-js/types/types/index.d.ts","../../../node_modules/@types/react/jsx-runtime.d.ts","../../../node_modules/@lynx-js/react/runtime/jsx-runtime/index.d.ts","../../controls/dist/base/control.d.ts","../../../node_modules/@lynx-js/react/runtime/lib/runtime-marker.d.ts","../../../node_modules/preact/src/jsx.d.ts","../../../node_modules/preact/src/dom.d.ts","../../../node_modules/preact/src/index.d.ts","../../../node_modules/preact/hooks/src/index.d.ts","../../../node_modules/@lynx-js/react/runtime/lib/core/hooks/react.d.ts","../../../node_modules/@lynx-js/react/runtime/lib/snapshot/lynx/runwithforce.d.ts","../../../node_modules/@lynx-js/react/runtime/lib/lynx.d.ts","../../../node_modules/preact/compat/src/suspense.d.ts","../../../node_modules/preact/compat/src/index.d.ts","../../../node_modules/@lynx-js/react/runtime/lib/snapshot/lynx/children.d.ts","../../../node_modules/@lynx-js/react/runtime/lib/snapshot/lynx/element.d.ts","../../../node_modules/@lynx-js/react/runtime/lib/snapshot/lynx/portalspending.d.ts","../../../node_modules/@lynx-js/react/runtime/lib/snapshot/lynx/portals.d.ts","../../../node_modules/@lynx-js/react/runtime/lib/snapshot/lynx/suspense.d.ts","../../../node_modules/@lynx-js/react/runtime/lib/core/hooks/uselynxglobaleventlistener.d.ts","../../../node_modules/@lynx-js/react/runtime/lib/core/globalprops.d.ts","../../../node_modules/@lynx-js/react/runtime/lib/core/initdata.d.ts","../../../node_modules/@lynx-js/react/runtime/lib/core/background-function/run-on-background.d.ts","../../../node_modules/@lynx-js/react/runtime/lib/snapshot/worklet/call/runonmainthread.d.ts","../../../node_modules/@lynx-js/react/runtime/lib/worklet-runtime/api/animation/effect.d.ts","../../../node_modules/@lynx-js/react/runtime/lib/worklet-runtime/api/animation/animation.d.ts","../../../node_modules/@lynx-js/react/runtime/lib/worklet-runtime/api/element.d.ts","../../../node_modules/@lynx-js/react/runtime/lib/worklet-runtime/bindings/types.d.ts","../../../node_modules/@lynx-js/react/runtime/lib/core/main-thread-ref.d.ts","../../../node_modules/@lynx-js/react/runtime/lib/lynx-api.d.ts","../../../node_modules/@lynx-js/react/runtime/lib/index.d.ts","../../../node_modules/@lynx-js/react/types/react.docs.d.ts","../../../node_modules/@lynx-js/react/types/react.d.ts","../../controls/dist/base/corner-badge.d.ts","../../controls/dist/base/disposer.d.ts","../../controls/dist/base/press.d.ts","../../controls/dist/base/pressable.d.ts","../../foundation/dist/collections.d.ts","../../foundation/dist/culture/digits.d.ts","../../foundation/dist/culture/culture.d.ts","../../foundation/dist/culture/calendar.d.ts","../../foundation/dist/culture/date-format.d.ts","../../foundation/dist/culture/duration.d.ts","../../foundation/dist/culture/numbers.d.ts","../../foundation/dist/culture/strings.d.ts","../../foundation/dist/culture/relative-time.d.ts","../../foundation/dist/culture/index.d.ts","../../foundation/dist/enums/index.d.ts","../../foundation/dist/errors.d.ts","../../foundation/dist/exec/diagnostics.d.ts","../../foundation/dist/services/abort.d.ts","../../foundation/dist/exec/options.d.ts","../../foundation/dist/services/clock.d.ts","../../foundation/dist/exec/trace.d.ts","../../foundation/dist/exec/safe-executor.d.ts","../../foundation/dist/exec/index.d.ts","../../foundation/dist/icons/generated/glyph-svg.d.ts","../../foundation/dist/icons/glyph.d.ts","../../foundation/dist/icons/icon.d.ts","../../foundation/dist/icons/glyph-slots.d.ts","../../foundation/dist/icons/icon-fonts.d.ts","../../foundation/dist/icons/svg.d.ts","../../foundation/dist/icons/index.d.ts","../../foundation/dist/services/preferences.d.ts","../../foundation/dist/services/contracts.d.ts","../../foundation/dist/services/index.d.ts","../../foundation/dist/theme/color.d.ts","../../foundation/dist/tokens/generated/palettes.d.ts","../../foundation/dist/theme/theme.d.ts","../../foundation/dist/theme/control-colors.d.ts","../../foundation/dist/theme/variants.d.ts","../../foundation/dist/theme/index.d.ts","../../foundation/dist/tokens/generated/metrics.d.ts","../../foundation/dist/tokens/layout-metrics.d.ts","../../foundation/dist/tokens/css-vars.d.ts","../../foundation/dist/tokens/index.d.ts","../../foundation/dist/index.d.ts","../../controls/dist/popup/types.d.ts","../../controls/dist/display/shimmer.d.ts","../../controls/dist/sheet/options.d.ts","../../controls/dist/provider/settings.d.ts","../../controls/dist/icon/icon.d.ts","../../controls/dist/base/selection-item.d.ts","../../controls/dist/base/timers.d.ts","../../controls/dist/base/use-controllable-state.d.ts","../../controls/dist/base/use-stable-callback.d.ts","../../controls/dist/base/index.d.ts","../../controls/dist/fields/dictation.d.ts","../../controls/dist/fields/slot-layout.d.ts","../../controls/dist/fields/outlined-field.d.ts","../../controls/dist/fields/validator.d.ts","../../controls/dist/button/visuals.d.ts","../../controls/dist/button/button.d.ts","../../controls/dist/button/header-action-button.d.ts","../../controls/dist/button/icon-button.d.ts","../../controls/dist/button/nav-card.d.ts","../../controls/dist/button/safe.d.ts","../../controls/dist/button/safe-tap.d.ts","../../controls/dist/button/vertical-icon-text-button.d.ts","../../controls/dist/button/index.d.ts","../../controls/dist/cascade/model.d.ts","../../controls/dist/cascade/cascade-panel.d.ts","../../controls/dist/cascade/index.d.ts","../../controls/dist/deferred/readiness-signal.d.ts","../../controls/dist/deferred/deferred-content.d.ts","../../controls/dist/deferred/index.d.ts","../../controls/dist/display/activity-indicator.d.ts","../../controls/dist/display/culture-date-time-label.d.ts","../../controls/dist/display/progress-bar.d.ts","../../controls/dist/display/separator.d.ts","../../controls/dist/display/title-with-line.d.ts","../../controls/dist/display/index.d.ts","../../controls/dist/edge-panel/types.d.ts","../../controls/dist/edge-panel/edge-panel.d.ts","../../controls/dist/host/layers.d.ts","../../controls/dist/host/back.d.ts","../../controls/dist/host/readiness.d.ts","../../controls/dist/host/registry.d.ts","../../controls/dist/edge-panel/helper.d.ts","../../controls/dist/edge-panel/index.d.ts","../../controls/dist/expander/expander.d.ts","../../controls/dist/expander/index.d.ts","../../controls/dist/host/hooks.d.ts","../../controls/dist/host/host.d.ts","../../controls/dist/host/keyboard.d.ts","../../controls/dist/host/page-loading-overlay.d.ts","../../controls/dist/host/index.d.ts","../../controls/dist/icon/slot.d.ts","../../controls/dist/icon/swatch.d.ts","../../controls/dist/icon/index.d.ts","../../controls/dist/pickers/trigger.d.ts","../../controls/dist/pickers/combo-box.d.ts","../../controls/dist/pickers/date-time.d.ts","../../controls/dist/pickers/date-time-picker.d.ts","../../controls/dist/pickers/picker.d.ts","../../controls/dist/sheet/height-memo.d.ts","../../controls/dist/sheet/stack.d.ts","../../controls/dist/sheet/processing.d.ts","../../controls/dist/sheet/service.d.ts","../../controls/dist/pickers/picker-sheet.d.ts","../../controls/dist/pickers/timespan.d.ts","../../controls/dist/pickers/timespan-picker.d.ts","../../controls/dist/pickers/wheel-column.d.ts","../../controls/dist/pickers/index.d.ts","../../controls/dist/plus-button/model.d.ts","../../controls/dist/plus-button/plus-button.d.ts","../../controls/dist/plus-button/index.d.ts","../../controls/dist/popup/frame.d.ts","../../controls/dist/popup/input.d.ts","../../controls/dist/popup/input-form.d.ts","../../controls/dist/popup/popup-view.d.ts","../../controls/dist/popup/queue.d.ts","../../controls/dist/popup/service.d.ts","../../controls/dist/popup/index.d.ts","../../controls/dist/provider/contexts.d.ts","../../controls/dist/provider/hooks.d.ts","../../controls/dist/provider/provider.d.ts","../../controls/dist/provider/index.d.ts","../../controls/dist/range-slider/math.d.ts","../../controls/dist/range-slider/range-slider.d.ts","../../controls/dist/range-slider/index.d.ts","../../controls/dist/selection/model.d.ts","../../controls/dist/selection/selection-sheet.d.ts","../../controls/dist/selection/use-selection-model.d.ts","../../controls/dist/selection/index.d.ts","../../controls/dist/sheet/frame.d.ts","../../controls/dist/sheet/header.d.ts","../../controls/dist/sheet/loadable.d.ts","../../controls/dist/sheet/sizing.d.ts","../../controls/dist/sheet/motion.d.ts","../../controls/dist/sheet/sheet.d.ts","../../controls/dist/sheet/index.d.ts","../../controls/dist/swipe/model.d.ts","../../controls/dist/swipe/swipe-view.d.ts","../../controls/dist/swipe/index.d.ts","../../controls/dist/tab-bar/metrics.d.ts","../../controls/dist/tab-bar/model.d.ts","../../controls/dist/tab-bar/tab-bar.d.ts","../../controls/dist/tab-bar/index.d.ts","../../controls/dist/tabs/model.d.ts","../../controls/dist/tabs/tab-view.d.ts","../../controls/dist/tabs/index.d.ts","../../controls/dist/toast/store.d.ts","../../controls/dist/toast/service.d.ts","../../controls/dist/toast/index.d.ts","../../controls/dist/toggle/checkbox.d.ts","../../controls/dist/toggle/checkbox-math.d.ts","../../controls/dist/toggle/chip-group.d.ts","../../controls/dist/toggle/switch.d.ts","../../controls/dist/toggle/index.d.ts","../../controls/dist/index.d.ts","../../controls/dist/fields/use-dictation.d.ts","../../controls/dist/fields/use-text-input.d.ts","../../controls/dist/fields/editor.d.ts","../../controls/dist/fields/input-policy.d.ts","../../controls/dist/fields/notch.d.ts","../../controls/dist/fields/pin-entry.d.ts","../../controls/dist/fields/text-entry.d.ts","../../controls/dist/fields/search-entry.d.ts","../../controls/dist/fields/index.d.ts","../src/model.ts","../src/barcode-text-entry.tsx","../src/index.ts"],"fileIdsList":[[41,95,96,127],[102,103,108,114],[41,103],[41,102,103,108,114],[41,122],[99,102,104,106,108,109,110,112,113,124],[41,114,115,116,117,118,123],[104,105],[102,108],[41,95,127],[41,95,102,111,127],[102],[119],[121],[120],[41,95,97,126,127],[41,104,124,125],[42,85,86,87],[53],[42,77,86,87,88,89,91,92,93],[42,85,86,87,89,90],[85,87],[42,85],[49,77],[43],[44],[51,55],[47],[41,51,55,56,57,58,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,78,79],[47,51,55,77],[47,51,55],[56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,78,79,80,81,82],[47,51,55,59],[47,60,63],[46],[48,52,53,94],[44,47,48,49,51,53,54,55,83,84],[44,47],[52,85,94],[45,85],[46,47,55],[45,46,50,51],[49,85],[38,39,40],[41],[100,102,103,107],[100,101],[97,127,171,181,252,294,295],[97,295,296],[97],[127],[98,128,129,130,131,177,178,179,180],[98,127,130],[171,176],[98,127,171,176,186],[98,127,171,176],[186,187,188,189,190,191,192,193],[171],[41,171,187,189],[98,127,171],[127,171,195],[195,196],[127,171],[41,95,127,171,198],[198,199],[173,201,202,203,204,205],[98,127],[127,176,207],[127,207,208,212],[207,208,213],[127,171,176],[41,98,127,171,176],[215],[41,287],[182,183,184,185,286,287,288,289,290,291,292,293],[127,171,176,183],[41,171],[41,171,292],[41,185,287],[41,95,127,171,184,185,285,286],[209],[127,171,209,210,211,212],[41,127,171,209,210,211,212],[209,210,211,212,217,218,219,220],[171,209,210,211],[41,127,171,175],[176,222,223],[181,194,197,200,206,214,216,221,224,238,241,248,252,255,259,266,269,273,276,279,284,294],[127,171,177,225],[127,171,225],[225,226,227,228,229,234,235,236,237],[127,233],[127,177,225],[127,171,225,235],[127,171,177,184],[127,227],[239,240],[176],[127,239],[127,172],[172,242,243,244,245,246,247],[127,243],[171,172],[127,242],[172],[127,171,172,212,243,246],[41,171,175],[171,175,249],[175,249,250,251],[127,171,175],[127,171,172,174],[253,254],[177,256,257,258],[171,174,177,233],[256],[127,171,174,230,231],[127,174],[174,230,231,232,233,260,261,262,263,264,265],[127,171,173],[263],[127,173,176],[127,171,231],[174,212,230,231,232],[127,174,231],[174],[267,268],[127,267],[270,271,272],[176,270],[127,270,271],[274,275],[127,274],[277,278],[212,277],[41,98,171],[98,127,171,177],[280,281,282,283],[41,98,127],[134],[133],[133,134,135],[133,134,135,136,137,138,139,140],[139],[144,146,148,149],[145],[139,144,145,146,147,148],[144,147],[153],[152],[151,152,153,154,155,156],[132,141,142,143,150,157,160,166,170],[143,145,147,158],[145,147,158,159],[143],[161,163],[161,163,164,165],[161,162],[142,161,162],[162,167,168],[162,167,168,169]],"fileInfos":[{"version":"c430d44666289dae81f30fa7b2edebf186ecc91a2d4c71266ea6ae76388792e1","affectsGlobalScope":true,"impliedFormat":1},{"version":"45b7ab580deca34ae9729e97c13cfd999df04416a79116c3bfb483804f85ded4","impliedFormat":1},{"version":"3facaf05f0c5fc569c5649dd359892c98a85557e3e0c847964caeb67076f4d75","impliedFormat":1},{"version":"e44bb8bbac7f10ecc786703fe0a6a4b952189f908707980ba8f3c8975a760962","impliedFormat":1},{"version":"5e1c4c362065a6b95ff952c0eab010f04dcd2c3494e813b493ecfd4fcb9fc0d8","impliedFormat":1},{"version":"68d73b4a11549f9c0b7d352d10e91e5dca8faa3322bfb77b661839c42b1ddec7","impliedFormat":1},{"version":"080941d9f9ff9307f7e27a83bcd888b7c8270716c39af943532438932ec1d0b9","affectsGlobalScope":true,"impliedFormat":1},{"version":"c57796738e7f83dbc4b8e65132f11a377649c00dd3eee333f672b8f0a6bea671","affectsGlobalScope":true,"impliedFormat":1},{"version":"dc2df20b1bcdc8c2d34af4926e2c3ab15ffe1160a63e58b7e09833f616efff44","affectsGlobalScope":true,"impliedFormat":1},{"version":"515d0b7b9bea2e31ea4ec968e9edd2c39d3eebf4a2d5cbd04e88639819ae3b71","affectsGlobalScope":true,"impliedFormat":1},{"version":"0559b1f683ac7505ae451f9a96ce4c3c92bdc71411651ca6ddb0e88baaaad6a3","affectsGlobalScope":true,"impliedFormat":1},{"version":"0dc1e7ceda9b8b9b455c3a2d67b0412feab00bd2f66656cd8850e8831b08b537","affectsGlobalScope":true,"impliedFormat":1},{"version":"ce691fb9e5c64efb9547083e4a34091bcbe5bdb41027e310ebba8f7d96a98671","affectsGlobalScope":true,"impliedFormat":1},{"version":"8d697a2a929a5fcb38b7a65594020fcef05ec1630804a33748829c5ff53640d0","affectsGlobalScope":true,"impliedFormat":1},{"version":"4ff2a353abf8a80ee399af572debb8faab2d33ad38c4b4474cff7f26e7653b8d","affectsGlobalScope":true,"impliedFormat":1},{"version":"fb0f136d372979348d59b3f5020b4cdb81b5504192b1cacff5d1fbba29378aa1","affectsGlobalScope":true,"impliedFormat":1},{"version":"d15bea3d62cbbdb9797079416b8ac375ae99162a7fba5de2c6c505446486ac0a","affectsGlobalScope":true,"impliedFormat":1},{"version":"68d18b664c9d32a7336a70235958b8997ebc1c3b8505f4f1ae2b7e7753b87618","affectsGlobalScope":true,"impliedFormat":1},{"version":"eb3d66c8327153d8fa7dd03f9c58d351107fe824c79e9b56b462935176cdf12a","affectsGlobalScope":true,"impliedFormat":1},{"version":"38f0219c9e23c915ef9790ab1d680440d95419ad264816fa15009a8851e79119","affectsGlobalScope":true,"impliedFormat":1},{"version":"69ab18c3b76cd9b1be3d188eaf8bba06112ebbe2f47f6c322b5105a6fbc45a2e","affectsGlobalScope":true,"impliedFormat":1},{"version":"a680117f487a4d2f30ea46f1b4b7f58bef1480456e18ba53ee85c2746eeca012","affectsGlobalScope":true,"impliedFormat":1},{"version":"2f11ff796926e0832f9ae148008138ad583bd181899ab7dd768a2666700b1893","affectsGlobalScope":true,"impliedFormat":1},{"version":"4de680d5bb41c17f7f68e0419412ca23c98d5749dcaaea1896172f06435891fc","affectsGlobalScope":true,"impliedFormat":1},{"version":"954296b30da6d508a104a3a0b5d96b76495c709785c1d11610908e63481ee667","affectsGlobalScope":true,"impliedFormat":1},{"version":"ac9538681b19688c8eae65811b329d3744af679e0bdfa5d842d0e32524c73e1c","affectsGlobalScope":true,"impliedFormat":1},{"version":"0a969edff4bd52585473d24995c5ef223f6652d6ef46193309b3921d65dd4376","affectsGlobalScope":true,"impliedFormat":1},{"version":"9e9fbd7030c440b33d021da145d3232984c8bb7916f277e8ffd3dc2e3eae2bdb","affectsGlobalScope":true,"impliedFormat":1},{"version":"811ec78f7fefcabbda4bfa93b3eb67d9ae166ef95f9bff989d964061cbf81a0c","affectsGlobalScope":true,"impliedFormat":1},{"version":"717937616a17072082152a2ef351cb51f98802fb4b2fdabd32399843875974ca","affectsGlobalScope":true,"impliedFormat":1},{"version":"d7e7d9b7b50e5f22c915b525acc5a49a7a6584cf8f62d0569e557c5cfc4b2ac2","affectsGlobalScope":true,"impliedFormat":1},{"version":"71c37f4c9543f31dfced6c7840e068c5a5aacb7b89111a4364b1d5276b852557","affectsGlobalScope":true,"impliedFormat":1},{"version":"576711e016cf4f1804676043e6a0a5414252560eb57de9faceee34d79798c850","affectsGlobalScope":true,"impliedFormat":1},{"version":"89c1b1281ba7b8a96efc676b11b264de7a8374c5ea1e6617f11880a13fc56dc6","affectsGlobalScope":true,"impliedFormat":1},{"version":"74f7fa2d027d5b33eb0471c8e82a6c87216223181ec31247c357a3e8e2fddc5b","affectsGlobalScope":true,"impliedFormat":1},{"version":"8e7f8264d0fb4c5339605a15daadb037bf238c10b654bb3eee14208f860a32ea","affectsGlobalScope":true,"impliedFormat":1},{"version":"782dec38049b92d4e85c1585fbea5474a219c6984a35b004963b00beb1aab538","affectsGlobalScope":true,"impliedFormat":1},{"version":"eb5b19b86227ace1d29ea4cf81387279d04bb34051e944bc53df69f58914b788","affectsGlobalScope":true,"impliedFormat":1},{"version":"ac51dd7d31333793807a6abaa5ae168512b6131bd41d9c5b98477fc3b7800f9f","impliedFormat":1},{"version":"87d9d29dbc745f182683f63187bf3d53fd8673e5fca38ad5eaab69798ed29fbc","impliedFormat":1},{"version":"035312d4945d13efa134ae482f6dc56a1a9346f7ac3be7ccbad5741058ce87f3","affectsGlobalScope":true,"impliedFormat":1},{"version":"07b03f752ae52a7130e06c5a8399d3a0dde07a1a634f8430b80cd6236c56b5c8","impliedFormat":1},{"version":"8a8eb4ebffd85e589a1cc7c178e291626c359543403d58c9cd22b81fab5b1fb9","impliedFormat":1},{"version":"acbac4ca6cd4b2b459debc4a274535775cb6278a8315be383fafa623ab78f18e","impliedFormat":1},{"version":"e421d0b097c78304a2597c1f33da586630e1dc665ae381c0c36e5ebc4aaf4566","impliedFormat":1},{"version":"adf624c89a0d509a789f3c0bf522969d2c47033dbeb50920b37cd89be475a65e","impliedFormat":1},{"version":"8ff8dade82d215fba372ec8ca795cb433997a41287e049acf294dd50cba08cc4","impliedFormat":1},{"version":"b32b532dcbe0a91d71fd94cb780e94bdfdce10be21608d914c29fb4b8939b24a","impliedFormat":1},{"version":"eb2b64881998b562a4fe9330e55aa2466cd3a41a1a57e93feac6555218cec06f","impliedFormat":1},{"version":"6db1694d205177322d792d924335b046b80607445a45c0d2de1fcffd190b48c0","impliedFormat":1},{"version":"2b47193137d251e8a5d4cea2d67fe85a68199795ba019e41d635f7cf5f8a35c5","impliedFormat":1},{"version":"f7e5c3960dd9df65d83408b9be446f7119fa1db1dd8266dd343349d90c3bf2ce","impliedFormat":1},{"version":"09c6491ed74af89a4155feafedecaf77780f5751c66d4b65b18d30fc0e053a75","impliedFormat":1},{"version":"188b01044640e5ef65f6edf0dd6e6454f02dd19f4ead66b9e03ebe26cc7298ca","affectsGlobalScope":true,"impliedFormat":1},{"version":"c2be64f223b024c0b70c5096a8c361c9e11c7644f3bd8325d19c2720ee7087cd","impliedFormat":1},{"version":"5bf51107315834a209b08395b141e262b7d143d14f6b4e4d403d8e020cef7e32","impliedFormat":1},{"version":"db0dcbe48d5cb38315083b412c8ab6995b0d42dc73b286833e296827feb0e5b4","impliedFormat":1},{"version":"b3e4a49a3ba19463662e7b821544948b953d2f6708370d42406bda558084000c","impliedFormat":1},{"version":"90bebc017d1c8408719f5a056813cce04e171a53469c263a136c35076121bab0","impliedFormat":1},{"version":"0675f9dddf11b81ec71825d5d97fdd789e445003506255513e0fc829ebfb795a","impliedFormat":1},{"version":"32d1e153cac16ca3a3f5f6b68fae76cddcda509950fa00d038c465776359db0c","impliedFormat":1},{"version":"0d85d0fa55dd433acf924675d7e976c025c8521c91a76079844cd15e52855ccf","impliedFormat":1},{"version":"89da6ea3ee9735e712691227b0e5ee74381779f9ad8b0f4fb7ced0247b16735a","impliedFormat":1},{"version":"37f90d8b4384dae49b873e620b7fff15655c706105104809114ba98df6373124","impliedFormat":1},{"version":"7618f7fdf0abf7f712cefe766ac1ab7fcd1f8e753c513e57d3ada9ada3a57257","impliedFormat":1},{"version":"759df9936f492afeacebec2cea4efafdb647951e0e5edfc4c677ce2441eac9d0","impliedFormat":1},{"version":"8d8848528b40a84ab42200e89d08f3d5cd83efa275de1bb70ae38cb9e6fd5911","impliedFormat":1},{"version":"0e323630cbfda771430e2720f6a2f02f257becd8fb9722aa975ae773fb572210","impliedFormat":1},{"version":"56dbc770513baae28f7cfbadeba5078bb13a37a13132a5292e98a8b103312b98","impliedFormat":1},{"version":"84ff906032fe12e816bfb7441cee6726243e5a7316c4f2d6b0a6c149f1a91a16","impliedFormat":1},{"version":"a8641f25f667160f356c504936576de22899e50ea575d7a4da47fe3b3704dd93","impliedFormat":1},{"version":"dcbbe1fb0f2c0efc12e29db8bbccb5b82513384d01d7a55342065cb0611da272","impliedFormat":1},{"version":"af209189a194cf5ad1f7b22dd680b52843fec2e30f1283be20b2977872fd4424","impliedFormat":1},{"version":"14745f699217e89ff1034f7be978bc28c195472a597b5f36442ef83d954d47b0","impliedFormat":1},{"version":"10c1feac0328f8f90a81f348b7f3c6d3c3b3454e46fc045ba1a706406c58fd8e","impliedFormat":1},{"version":"f64cd565aca17df45f4666473da75e4ce51a2610e2ed1c31198e9f9325747a24","impliedFormat":1},{"version":"e415a17ab6a413d6be640457231e045541405eab1f0f370c7dd1e5567aa25999","impliedFormat":1},{"version":"8c03a41d6dc701b6648db83d71a92dc27147d7677ab5d70f32675e7e37b3795a","impliedFormat":1},{"version":"09c18bc60888c58e8f4568b6ca973af72613a8a01e7b213aab778e910ae18b2f","impliedFormat":1},{"version":"5258d7af58615ea380d959cbcb6d83cb7b9841b8c8267f5a0fcb36c092dadbdb","impliedFormat":1},{"version":"b2d74af681f440a07e714ae9a33e3ea49c79870b9674058114c0404d2aa2f190","impliedFormat":1},{"version":"24f31e43eb3505e5d2946315e7b8ee8b426dfbe92c3031e435a4eb2d9dd8d69f","affectsGlobalScope":true,"impliedFormat":1},{"version":"679f7b45a77210e6dd0d72a4b81fd177868d2eacfd8ee6919ce6babd7512562d","impliedFormat":1},{"version":"c669ee7ba01fa6a60b17c3535f96b65fa82dfd2a475a8760364f2f3952f9bcbd","impliedFormat":1},{"version":"a8b121f6a75d603075e62793ff0c109112e882dd6ca2b70bdccbd8d8f753429b","impliedFormat":1},{"version":"f378d7ed5e3ecbe382ade55127a9c98e826c76f786e06effad6fde91a7023d55","impliedFormat":1},{"version":"4e3e9539df72b3bfcc56fa13140070020dac72f1eff39237b11253482cb99847","impliedFormat":1},{"version":"5a47b3a2bbe2c9b015fe356462afe0abe391c592fffbe277126e2415e0811967","impliedFormat":1},{"version":"a3e797c70a421cda37cdea4349dced37dceb1611669652d9c4c5523467a55cbf","impliedFormat":1},{"version":"9164e652ff4e7cbd993ca20acd0e2ad7e1cb775a7aefc577b506cf588763ec42","impliedFormat":1},{"version":"e52840670587e82e129c9bfc6a2f42d9c2f2e1fd6ce176fea998383a8c941ea5","impliedFormat":1},{"version":"31ca1ee726f5d7c7709913b98be76fc40fdfaaca6ad7fafc222108981e11227c","impliedFormat":1},{"version":"556db73da59f5162cdf5c7ea1bc3b063b6ccb758078ef6517ad6f6e4ae7b199a","impliedFormat":1},{"version":"0a2c8ef08611f5a5f711c7b10ba70d10dc1c6af0c9dba8168cbbf34911b74188","impliedFormat":1},{"version":"1d6ef45145a9939a43062fe18188d4f7bdfdf4547978e1f6b7c9089fe53e81e5","impliedFormat":1},{"version":"42c169fb8c2d42f4f668c624a9a11e719d5d07dacbebb63cbcf7ef365b0a75b3","impliedFormat":1},{"version":"509a86836776d5c821901abc16a2d21de674d2c8943ceb8d018049bf324bc56c","impliedFormat":99},"83008ef2f468dd0dc7b3db86de82cff5e3a239748c8515f84f621b5ec5fdb07d",{"version":"8e609bb71c20b858c77f0e9f90bb1319db8477b13f9f965f1a1e18524bf50881","impliedFormat":99},{"version":"8a2ef120c4da7aab664148ed8d283aa0b98df4d5f15c570d830c8998ef05718b","impliedFormat":1},{"version":"4433d18f82991634feae5150a68f9b30f5b05b55416af8ff9f7251fb29431ed5","impliedFormat":1},{"version":"cc5d0b221824b7d8597e8a2bbdad2383af877eb564eaca392992049839e88c9e","impliedFormat":1},{"version":"21898d939444825cee1232af435330610b09171bea22a2f892cf2058d764b63d","impliedFormat":1},{"version":"6ec5f3b496e6f10c4f0a079e3b1102acef9c0bf5e3464909fa6e88b16a26480f","impliedFormat":99},{"version":"d9d320cf31f6d63659484f6c9ca4db4ae673daefa65118dd8589838925ff1397","impliedFormat":99},{"version":"027cf2216d065a97bf5a8ea126b3ea2734fab6cfe32adaff81ab4e94a1b51bbe","impliedFormat":99},{"version":"f6e6313fad233c5141220f7d25eae120cdd6e5079fbe0aba56821a1e99d05df8","impliedFormat":1},{"version":"9534c35b4577c193e499178deb47419fdadddd5e53af5ec8cb88218848013f65","impliedFormat":1},{"version":"804dca323c25404588a6e71d76e52eb09806f05e6013f0be1fcea1fb7eed5fa3","impliedFormat":99},{"version":"aeba529dfa69caa0efcdee1f1455540250d026522e5551b20b8a7ba9eebc707a","impliedFormat":99},{"version":"dfe6945467765f8e7843442a9dfbcf6b5526b6465b07b4c75a54a750329b5f17","impliedFormat":99},{"version":"7f9f6c9fe0e48c401d855d849e28112ffe2425569eca01b08b8c6112b8200695","impliedFormat":99},{"version":"68fcdc663627d12d336b420b19b3e54258844d0cbca0879f711c22aafd853352","impliedFormat":99},{"version":"6e97a7762ca61b836f275a14bf22a1696559bfa01bd6176df9498e717b5ff298","impliedFormat":99},{"version":"86535783bd695ee43e1a403e8cc50b1d643d3741df8074d30fbfae3b0438f996","impliedFormat":99},{"version":"7c94c072f4eef88b15710e2a6dd17036bfd943b390976aecc94af63df2f8a287","impliedFormat":99},{"version":"7e8a2efc54958a4ea7d678671d8703b00ae48a519d0f795a8f44f605abdba3d5","impliedFormat":99},{"version":"1409a9680115403cac91934df0062646e0a77f1b220b60faec5fe26cd775d9ca","impliedFormat":99},{"version":"335226d599a9382c9bea07d37e23bf998c1022c0f67e4d6d2b69633de6ac118f","impliedFormat":99},{"version":"ae430fd9bac320e71c3fe9299d90dcf67555d9a4f97ecaa35947b430ba8648ea","impliedFormat":99},{"version":"9061ff14146280f47d740b344ddd641c16df526ecaa868c348852277a9fb8686","impliedFormat":99},{"version":"7fa70acc5eed701b456f21e33f8f289e9e0e77fdd1f952385c33d6b9ecfb2021","impliedFormat":99},{"version":"16c6bbe197b6bf88db162c620e37218fab4c1c32892132d4aa33e461ae2b990a","impliedFormat":99},{"version":"9778598e1d86d1e544ab77fbc0bb5199d2fbb08ed386b3520732246b90005545","impliedFormat":99},{"version":"feed66ae8815d1981ad575482766fb9a82385e75cce35ae2f13be58e50c4349f","impliedFormat":99},{"version":"7e500d1f51b14c04c6dce8dcbadc5c48f4bec6fca0f321397c165868834916a2","affectsGlobalScope":true,"impliedFormat":99},{"version":"20c1041fbd4f1537686af4b707872b87c90a22201f8979e5def4554d28b46a5b","impliedFormat":99},"1492a06643311a66d01dc0c15259c0dbe7c4d336e7a85cb7ece67085afd2e84f","47ace7a5fa09cb19907ed7cb83a867b05ecff3e10bb229888e24f82b2c03b869","6d878f3072ec5afa5c70f9c13668a98d3bd737a60b9570f6fee4c876f0785fb5","09cd0995d324e6b1c3ab3b22b12d1df84986e2c201447a07b2a7a7b8e43b5ae8","d533d1fe3018752aa47ee74ae5dbdca34377441b891176ad99bd33366a64372f","44b82e4f46178400732ea809a906f7ffb9dd38efab331ca23e7ca4586bf903ef","d5621f942ab05c1c3594b5b59070c2f44d411f01ba97eae6bd60cd99ab6be102","69af30b9df408f844bd30e26ade1ba783c7624bd505ecef61a7e178624ece0eb","3dd51a4b01e4a63709253bf28547f961d6bc64df7b7ced76bc0771800446ecd4","28b43630d8d29a300e1e5b0f5efb04c8f994d372fff1b653ce8bb70d4e011e1a","2064567cac7c44696477d8faeb79ec714624c341bee71ea7237ea2ef2e26e8a4","2e41c86f134947bc0814e4835be773754c58ce89f1a1ed98845fa894db8e13f5","ddb01c2474a47c2411bde75e969c547fd52dd0de9d39837970a6ec5effea934f","d1c0c41bd9714bf0fd2a8676cf3ca6f2adb012af6f07411bfe2f95bd776a2548","e60dd3f69310681e28813b910da7d57f5cf0078feccfd683d22a29b45bb7a035","ccd708c3fff99b4ec315e14315dce6b9e85f4c96d10131e9fd219edb6efbdb26","abc924fce33b86b9f8588de3a5be04c609fafa6cb1dc42629b3e9e3e18f7d018","f919e3a8b2d274b631ee4fee0c50eba1d3f39ceaccba04dff915e9f61e9f153c","db505b070be7771c50bb80800e4a16333bea91619030d33e9d1b1d6d245fde72","d1b2970d348eb9f89ef0f0c6730d27e9331067a28f21c8bd667ba1138d5d3e93","cefcb1f078d33a40c707d4a239ee518a595d7553b4205a4a23c1bf84a743a94e","4f83143f730ad8fd66ec8f779b2f43399ed4b84aec6f5df5fdc4a2436739e934","830e8c15e2893c5864835fe97bad3fdc5d46bb9b72a66851365b8411347dda10","b24ac81f4fcff56ed9827736abcf2f92ea5f86e16d66eb2ee3ccfa0bb8143bc9","068309ff581d08c276c4a772ddf3ab9c8090e591fc9917fdc6cdffc12c95a5bf","831a6d491136030d2bc354358087a756bb67ae7118310122dd7c2c2fcbfd6bc0","2b8a3fa14f4b24cbb3c2c783ae0805bc1a857cdf7d35308956f3660ef0229c3c","62412b4c4aa6d31b2179073bbfa02be1029f66b852d0a1d21bcb936b263d496c","e03fb91a66dd8cfa60c43702e242cde0a6762a3d805ce3a4bbf88446d3da1682","40228f7d40928971ef8caee096b4eef83b737e49e01259b593f963a02f7f6474","ee4e73f46ce2f6517e82434bd9fc63c8b6b2179d37d74525899f124a76d06669","16398f80eaf7b611f1771a8a30621007cabec8fb504b9ded95a26bf245613fff","0da9bbeb48befd4d8bd4f6cb993d318d8dae710441a591b0de516f6fe13335d8","c15fea45b893c73bcad76ae565d59a0472ae0f74713ead9a9e7eb37085260c09","faa64d270fa523f80fd31bc7340ee7f6a21632c2ea0cea6535bf5a34bcc6adf7","6ca0f2e5903da1bd2557eb1774911a2d79c1f1effbaa179c4b7b3ad45e2c44c0","edc33c8870895bd9b0255d99fc8213efeddc0acf0031b7fa6cd8cc372f446c46","9e4bc453892735c30e822d5b299e8de4239378698a0b2cc474b191f06475a661","fe159e8ea7f4a98651439d64f7006c5204db2fde191c424c780ec740bf9010bb","613df14d2c8c0ba78286705c4ed01ec701ed03189ca3803dd69bc7086b9c02ff","298f8d2584216932ea238927177ef343d0b8da735eb40a5ba96b1f92e3675e33","1862daa6bc69b267a2b595149c5bced13ce2440d0d6625d291a5450d9d3118ae","db3e0d2de3bbd4e59b57c9ac451973bc81f9525cc1c9e2f431350327040fbc5c","5fd48f5d7c97007cb419ab6d7d405b487e0b045bd0692dcf8342cdb75bfb3388","9ec4e6a2fe6d43759242f8d280488356ee2e4cd3f5d12356408b00ea5d1832c4","c1e64c51dadfcea7b7995040c64b5ac7e8f954f2a4adf4eb92e7a462ba5275e8","f021082a3c981358b5110cb24d0139343e55c460a65067857638111d82e1c894","618baaea457908b278ffbc8314948a91d7e8b227092e8376e690fc10d6584850","39cce160c9957c4ace47342334c01a6c666f04a748326430a52250655471fece","7d4e7a4c886e60616fda93f47d859e401aef8718dc2296fda7edcd4e936ad9f7","665236eec0c0da8d3f7cdba8f01f98233425d8c065058e513b33385e417a56d2","50e8918146f4e8a9240bf867a07cf8aa0deb21fee8d4507e74ff62c8c6af42e9","666640b08e3ce76b6a8c76ce1f9f5b986923d3c76663b7fa4bc36e3af734ec46","46cd7daf86c8e3a946584d94646dc41882f73da95ca2d0f5d076db10e5cf63a8","81a2560c073f9b6b2a9905920928047cb1015307e573896319c6f0c545509d2f","e66bcb283e827cf0eccbf7795782b8d29963d75ca6a0d19f5ebee62d0f3ba527","64e4a0167f003d4d3213ce53528c09770218a136b2fdc8909802d0b07f4e04ad","84cd1439e1dd7acff9eadb61505b0b00472b49cfbeae20bd35180b565cc83f27","fc20037da0ee727162eafe9263777bf740ae1c8c9d9ceb8a03479fc03033604e","c8c85f89d1f4dd4f267c2f69442e69db39831281bfa63f0cbb089bcb286e4b2a","d012e46caf5d4901396b52c9a9477c1aee797dbcdae0bab337d9b551cb57da3e","9e9db82d9d2b90060c9973f14c25ec3948b6956906d8cc5347ba6e404b70c22c","d97725bbbf0a17d7fb27c67eff463268b6054c6af141a65fca3c7d01ed3d22c9","742d8e2235c5fc1f3a5eb4509a69acc176fee745298eca3a6321e482c79ff855","12b36faab2cca51d73cf516f5b1d623d1b9aa65199112b6678db5af1c2c3c8f5","0dec81ec440913b96d8773df77629d3636530925e5a87f7587132b9af532bde4","def60c6a4a8f8a5a9fb6d203a49ff97ea458e5b455547cb3eab3925de119b029","e24ba8dd2891c4f553d9f607721a0c2f2edd5454cdad96dba6466e4bc0e6fddc","37d407dd374022c56fe91a63b772be83ef15756fbecaed7d984e5c0e2e434c6c","160231f9c5b886a5544e519fa5cbb4697f0a90b7c5049e59b3b434429a4ddfbe","5c2c855cd63f6c959fa374e0a24781ddf820473765bcfd343d6ed222e54a16fe","90abf489c8a42db8f34623d833ff259d79f7b599c6410c8a23119727c7b361ff","6ae379d8f2c86a11844e6e50e51d773fa4cd21da5597d55bcf2a978b29628e2c","cd64b34e8875a6ac5d727f237344998d529ad7a4bef401908de1587cc8c8c7ca","355510dea329d959729f2774e17ec5f67759dac12fb21f9bef53ae3fff84e759","59039f8b2b14d807bc979b9dc9b7477f047321f5317ac27637b9442efd35caea","a8d2e79a9c101d18d040fdcd6e9c0fae39a9cbc734ce5039b73f109064500bf9","947ace4cab1f18a5519db930963c4a21791648c9f6eeeaee30ca641260b95825","4ebebf8eea7772198c523578e3836bfee4acda90c9c288ad18f4d75b380c22a1","0d8109d5f6bdc3169bc72c561847b746c18363bf1dd2959d7a67b3d9d735fb94","57c794e0d8f70a1bafb6f0d3fbe32fb0a8bc1026e29b2b8a9bde5a3d5d6ae92f","a0ade903bb94ae5c3318dd83e268282cc943122b9a5d0860ed73a1abc056a7da","8335fec3c9e999648f83fa790d974658c8910eac5bdf501d083aba733c8faf8c","18c56c5a13d01291c50fbae2658bd5f7a2f94984071a4cf1c302869287002470","e9ceb9566aa4790f00f1d2ec3853c54bb3f7ae03bf1a1ab503c48f45bf079388","4f17c7c8864b0fa43fd0109cabb80319a08c3b0f8e21fc51c76a598a52470140","299bac5871f6b975d64c593f6f8a4114ca9b78400f911dd16f7ec697349331d0","91fcc22cca0e21a86f6b13650309619abaad462239d2ec00ffd604d9be6bf3e1","8f1be9d32b0f8b427c43a283dbc5cc49af7df9c7908657c9c906d4872116ae6e","52e6f3eb4ebe7e2e40ea3c3a6cf2bce4462cb4ce6d85b18bd2d0df32208b98d3","c8a3bce512536961ab76133fcbbf0bceab013dbf87b6695edd1e3eb3e6857905","a0f0c22f7b7afd4173cbe844a19ea1adc7956f5fdbde6767c3e20a1e7dbc10dd","482923ec0d1e3817f9fbc00435690b10761fdbc95c8034b43d9b3a0622b820f0","984c07b76e6c8e8080255a7f89b311d05acf487d39d01c662d735184abe9e0f5","c622e8dc4d7fc57e66b0e81d94d619b07a1fb6828a3d41b91b193d95688c10b7","ee57677277db2c2c2b43ff9a860a1a77a47e904170fa856bc3b717d741da0955","05210561e98d902e689837f0ef63dc8fa08365c27ced981b97a64d9aef963c16","a9973353f17837c2d32234978a8c4c257302bc794a658cda5ca0bda5b2b76010","391d7640e2e35c5749b3cd1922619353e4412524a075423c62a402c2f159ef18","400a5d06125f3c534aa08e7a29acdde778910b20dbf7a018c8bbbb1bac7ca047","52c4ffa548e00cfc7c03a02e5dd0a5d113a39b5a6207793ababb5454512d0eba","806a3b6d74702902e8efaf9abcf83bbb475388294c254182aea09e2a198940d3","85d0b9f7d84dde00a6f5090983a97524851244c29d9d591312e9a35ba37f6f25","7a62d416ef40e12038f5ef4503dad2f953c9ca2dcfea3fd6e53384a58d5884d4","871df0eb283846c9a6acace32525f91663b09b6c339a42596357d992a682db86","b9d00d6425694057f86e25b1de18f7b1c33ef748d2e18c3349402f55a90e60f6","8703f5c9aa5babe37a8215964e0c266ee702f26e2edf1d387fb56d00782243a8","768383269a84ce64ceb69747b076090f472b2fe2799f7e131f7c8e9472a70e08","02b776968b2c32920d832984afb6b107b0be6351562d5b74a34ebf4c6c513c8d","1732e6941c747ac1aae4198d87c1be0a0d05ca3948e47830ee2716775de7feda","2f11e39535faa194e4665d4d45660bbc6437a531dda595ccb900e0db37010d03","dc4f13da67b9e0722744f9362b90a843c82ea587b556327ef52c07d333996cb7","556d497636fda2e83896f74efb05348e98bcf6eaad0fa2d5c4286bcf0fbb65e0","265d038148125f562cc35e2e7659504a355a8314f186997b94b0a2e1b61f365c","a7be88e03f64e1f5dab28fceae03216d7a33a57c523cf9b38eb9e4dcc4a2f6c4","0664a239564747c97c2ea129bee991fa436f8c44add5df0004fb3b9b3d2275f8","8dcd588a2207fa81fcdc0187c4210e8cb2c43a21c781188b547a3a0546763767","498d27e5cb9b09080779e29ee60a85cb0523b6070a3bdd6820032ec7d328bd82","78cdad8654218cf6a8ca9d0b723b222d6cd033a58f53180d3348999f84051652","10d7ef658db0ed60abb5fc51f87b6662b73a4508b8bd35a4eaa437ed0354fc29","089d3f855aaa1faf5acf9a8981654c78371c6df2e0cf0726e1593f781f88a999","7d8fe46a78abb56bd3bf5fd4f74f60e59ab648589763cc6e6f2eac69854775c3","db3cae86b9ed9446c5202971229a0b1756d6e62756cad097da05cddfd6e095c0","3bfaac790b30e5c219a32d6a09ca9ba9ae33836ccb167806fdf4050da60b2349","83cbfbf7004fde4e0b1ed5b3bc03f8e016f495e116874d75517fe73d19b80381","e54ecb99e7bbadda0d8d45d5bf708eb3c115edab9e926aea5f605133ca45c9c2","e6d30f57e88a1e168352f7fa6037077d93f98441f53236a8ed3d0cd6dd7cc5d8","27701ad0d6ce3c2ee26b54581084afb5bf2f94aafe6935e224fd9703569e5cc6","6de9f2a41325a1523ea7d720c6f4d2a6df568cd53aca65ac9c1dadf2ba00816a","ed6ced25512d5b0b09b0893df5da1131eb27fdfe7642886116d66bbcd5523447","a0db2aa782d104269dd4dfdf0b0be6bd87b8ab289f0b85d0b50fd235785061c6","1c9bc961defb24ccbae2b3571ca5d9e136b2efdade56e9cbb5da0aab6fea37a6","abd7a61e03b2b5599903f5f54e5fb0a721eb3cf3f2d10a776828fbee9d60a68c","b42aaa081a8e88f66049d9b0eee25210181f482e010cf955c52d2494a5151d6f","b1221b6adf30a65fec527f81156f71ac21e05fadfaee4247907b998b77fa1e7b","faa991fcf8da28e83533e2dfd90ac6f718c4903e41bbe063b9d943b51567eb7f","88415a5bdd4d98357e1377682162ead0513bbc511624d55aaa8a6b49dda108a8","23443687c6dd46249c8db5953b4e214031eefc7c5f1d85528c5a548006de10c0","14415f67a35942d7dc296f142578634492ec961cb0bef7803ff713d9411c411e","09f8b6061619e6f03e5c662483ccf651473b86cf5b8804be11f3f3d26e204aab","45e4be8e179288c2b09b859a47f71491ccb32f6e7c7da3b71f5f6061dad3b5e4","da03f7fdafe9f50db6d949577ffb2d4c5f1217631f07b33899d625ec27b441d3","18c41c21bd44352c9e3174c78c137cf1340e47b6c1a08c12119e27f97ba09239","e693ad19645499454818e939489c1b7855eb451e87a727ee166b23f9f479b0c5","6250b9e662d0bd2c94ad45e0690e6a0c19ca84fff27821e1e4365f81b88f3db7","032bb4c4dbcbae5735c4c15a2351e22bd8e7cce4e8e9e8cabe1e9def14b9813d","b267619f54077dc94be10da1105fa31fdd6a215e53ba2771ed5477a44a2911ba","c79c5800f6b1a4ad8ecb86a2a7a601a3fabd86b59211bbd03be7f55c88d9e9de","1b706f8dcd3171dc8ff23d5221020abc8d9bfc8e24f03d5952e95c4186b5256e","db5c5f8646906c6c576474f906f57a32b2f91972cce6455e1b6cc66b44005bd3","00150d38c1baf871536dabd3cbb903bae8e4c17622579e779c6361a93819d80a","a26b35d33230bd22168c73a689f0e153332af7f51d67647a2652cb0fbf6eb270","3cee3a9c59f062afb83fbe72cfa0fc1bb634433ca314df1e6525795ed41ee2ca","18118332cf60dfe061ef415b4bdf7189ed18d66ef897e4e4fcbe7024beb0e5b5","e853fa7b8c2c8df1e0b801a78168a12ace6bab9f9f39af467e9c8eae2fad5a95","9e1785d504db788b3d3a4bd3443cffa09a732e7ad46802d367b1a016b2604304","2582f7d6d1b97a9273e15a03a6d1feb26e258f2204d5d8d5237199571ad7a48c","9216eed660b8addf854a54455c1c797725448d954fcf3eaa03d1f181274e1718","d88767e77141e5d76b380dd987e4a94dfff884263feab1277320476760703133","6d2c2813d3b643d4fc0496dc95d967587cb45386da409d876327994654997866","7a7dff4c82a44efb726eafad3d256153148b1f5829ba28ef211fa5f782de4b3b","ae64b7dad8b449e736e6b21d8e327ea7cbd68fc5bdd01999e4c67f3896da4cb1","fe45a19f125e7c356c6bf78b890b384b01444c4124fede1d4c9cc0d667ef5501","35ef5e22ee548fc5e444c437cf660750a4f9345e955c00d940fb2aa2af2ab71b","fd4ff08c6e5f669a32ff23fdace3ed66ecdf427257a48c4bd6a97a18af4c7ec7","ac5126e7d56a4885bab3471a7cf265acdc9fbef8d71f5e8ec04f5864cc281798","2f200a7bcfeb5ceb280066b0809f9eb16bc7490962700b7501f7c6c981bfc726",{"version":"718f184436644e2d0aa68603e3fd898d7971781c041109f6adb7798ee3244957","signature":"c12315aaf6e405574a234bb676be6cb153aa3f0dbb14660c7435fab55c52a193"},{"version":"81054232f8b628d3404bb6e6b1aefae63ebf77fe8a2359ca313ecc96ac62e148","signature":"22b1d7be180f356be9588b26bdd22282c836ca6dd9b3d08f86d2eda05ad089e4"},{"version":"e6449ba209b1a93fdb60aa852dac8cb1a1e77a440e68ee15c76f198720d0bc40","signature":"1464f7e5d9977175ac8dae0816c904950449763d7022872bbf465dc39f734bd1"}],"root":[[295,297]],"options":{"composite":true,"declaration":true,"declarationDir":"./","declarationMap":true,"emitDeclarationOnly":true,"exactOptionalPropertyTypes":true,"jsx":4,"jsxImportSource":"@lynx-js/react","module":99,"noFallthroughCasesInSwitch":true,"noImplicitOverride":true,"noUncheckedIndexedAccess":true,"outDir":"./","rootDir":"../src","skipLibCheck":true,"strict":true,"target":6,"tsBuildInfoFile":"./.tsbuildinfo","verbatimModuleSyntax":true},"referencedMap":[[97,1],[115,2],[104,3],[116,4],[123,5],[125,6],[124,7],[106,8],[109,9],[110,10],[112,11],[113,12],[120,13],[119,14],[121,15],[122,14],[127,16],[126,17],[88,18],[90,19],[94,20],[91,21],[92,22],[87,23],[89,24],[44,25],[82,26],[73,27],[59,28],[56,27],[80,29],[57,27],[78,30],[58,31],[83,32],[66,31],[61,27],[60,33],[75,31],[81,34],[79,31],[62,27],[70,31],[71,31],[63,33],[69,31],[64,31],[67,31],[68,27],[76,31],[65,27],[72,31],[74,31],[47,35],[54,36],[85,37],[55,38],[95,39],[45,35],[46,40],[51,41],[52,42],[50,43],[41,44],[96,45],[108,46],[107,12],[103,12],[101,12],[102,47],[100,12],[296,48],[297,49],[295,50],[128,51],[181,52],[131,53],[177,54],[187,55],[188,56],[189,56],[194,57],[190,56],[192,58],[191,59],[193,60],[186,58],[196,61],[197,62],[195,63],[199,64],[200,65],[201,51],[202,60],[206,66],[203,60],[204,56],[173,51],[205,67],[208,68],[213,69],[214,70],[207,71],[215,72],[216,73],[182,58],[288,74],[294,75],[289,58],[184,76],[291,77],[293,78],[292,79],[287,80],[210,81],[217,82],[218,83],[221,84],[219,58],[209,51],[220,51],[211,58],[212,85],[176,86],[224,87],[222,71],[223,63],[285,88],[226,89],[228,90],[227,58],[238,91],[234,92],[229,93],[236,94],[235,58],[225,95],[237,96],[241,97],[239,98],[240,99],[242,100],[248,101],[244,102],[243,103],[245,104],[246,105],[247,106],[172,71],[249,107],[250,108],[252,109],[251,110],[175,111],[255,112],[253,58],[254,63],[259,113],[257,114],[258,115],[260,116],[261,117],[266,118],[262,119],[264,120],[174,121],[232,122],[233,123],[265,124],[263,125],[231,117],[269,126],[267,98],[268,127],[273,128],[271,129],[272,130],[276,131],[274,71],[275,132],[279,133],[278,134],[277,98],[280,135],[282,136],[284,137],[283,138],[135,139],[134,140],[136,141],[141,142],[138,140],[140,143],[139,139],[150,144],[146,145],[149,146],[148,147],[154,148],[155,148],[153,149],[157,150],[156,149],[171,151],[159,152],[160,153],[161,154],[164,155],[166,156],[163,157],[165,158],[169,159],[170,160]],"latestChangedDtsFile":"./index.d.ts","version":"5.9.3"}
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import { type G9TextEntryHandle, type G9TextEntryProps, type G9ValueChangeSource } from '@g9tm/lynxcontrols/fields';
|
|
2
|
+
import { type G9BarcodeAcceptor, type G9BarcodeScanMode, type G9BarcodeTextEntryState } from './model.js';
|
|
3
|
+
/** Where a barcode field's value change came from: the text-entry sources plus an accepted `'scan'`. */
|
|
4
|
+
export type G9BarcodeValueSource = G9ValueChangeSource | 'scan';
|
|
5
|
+
/** Props of {@link G9BarcodeTextEntry}: every `G9TextEntry` prop plus the scan workflow. */
|
|
6
|
+
export interface G9BarcodeTextEntryProps extends Omit<G9TextEntryProps, 'onTrailingPress' | 'isTrailingBusy' | 'onValueChange'> {
|
|
7
|
+
/** One call per change; `source: 'scan'` for an accepted scanned code. */
|
|
8
|
+
readonly onValueChange?: (value: string, details: {
|
|
9
|
+
readonly source: G9BarcodeValueSource;
|
|
10
|
+
}) => void;
|
|
11
|
+
/**
|
|
12
|
+
* Codes must match before they are accepted (MAUI `AcceptedCodeRegex`): a pattern string, a `RegExp`, or a function.
|
|
13
|
+
* Unset accepts any code. A malformed pattern or a throwing function rejects the code.
|
|
14
|
+
*/
|
|
15
|
+
readonly acceptedCodeRegex?: G9BarcodeAcceptor;
|
|
16
|
+
/** `'single'` (default) replaces the text; `'multiple'` appends `", code"` and keeps scanning. */
|
|
17
|
+
readonly scanMode?: G9BarcodeScanMode;
|
|
18
|
+
/** Allow typing as well as scanning (MAUI `IsEditable`). Default false. */
|
|
19
|
+
readonly isEditable?: boolean;
|
|
20
|
+
/** Placeholder while scanning (MAUI `ScanBusyText`). Default: the `Scanning` string. */
|
|
21
|
+
readonly scanBusyText?: string | null;
|
|
22
|
+
/** Controlled scan state (MAUI `ScanState`). */
|
|
23
|
+
readonly scanState?: G9BarcodeTextEntryState;
|
|
24
|
+
readonly defaultScanState?: G9BarcodeTextEntryState;
|
|
25
|
+
readonly onScanStateChange?: (state: G9BarcodeTextEntryState) => void;
|
|
26
|
+
/**
|
|
27
|
+
* The scan icon was tapped (MAUI `ScanRequested`): you own the camera; call `startScan()`, then
|
|
28
|
+
* `acceptScannedCode(code)` and `stopScan()` on the handle. Without it, the field scans through `services.scanner`.
|
|
29
|
+
*/
|
|
30
|
+
readonly onScanRequested?: () => void;
|
|
31
|
+
/** A code passed the acceptor (MAUI `Accepted`); never fired for typed text. */
|
|
32
|
+
readonly onAccepted?: (code: string) => void;
|
|
33
|
+
/** Symbologies passed to `services.scanner.scan` (e.g. `['qr', 'code128']`). */
|
|
34
|
+
readonly scanFormats?: readonly string[];
|
|
35
|
+
}
|
|
36
|
+
/** Imperative handle: the text-entry handle plus MAUI `StartScan` / `StopScan` / `AcceptScannedCode`. */
|
|
37
|
+
export interface G9BarcodeTextEntryHandle extends G9TextEntryHandle {
|
|
38
|
+
/** Enters `scanBusy` (MAUI `StartScan`). */
|
|
39
|
+
startScan(): void;
|
|
40
|
+
/** Back to `idle` from `scanBusy`; a scan through `services.scanner` is aborted and its late result ignored. */
|
|
41
|
+
stopScan(): void;
|
|
42
|
+
/** Validates and applies a code; `true` when accepted (MAUI `AcceptScannedCode`). */
|
|
43
|
+
acceptScannedCode(code: string): boolean;
|
|
44
|
+
/** Runs the built-in scan through `services.scanner` (what a tap does without `onScanRequested`). */
|
|
45
|
+
scan(): Promise<void>;
|
|
46
|
+
}
|
|
47
|
+
/**
|
|
48
|
+
* A scanner-aware text field (MAUI `G9BarcodeTextEntry`) on `G9TextEntry`: a trailing scan affordance (pinned right,
|
|
49
|
+
* text pinned LTR), idle → spinner → ✓ / ⓘ states layered over your own field values, an acceptor for scanned codes,
|
|
50
|
+
* and single or multiple (comma-joined) collection. The camera is never this package's: either handle
|
|
51
|
+
* `onScanRequested`, or supply `services.scanner` and the field drives it (aborting on `stopScan` and on unmount).
|
|
52
|
+
*/
|
|
53
|
+
export declare const G9BarcodeTextEntry: import("react").ForwardRefExoticComponent<G9BarcodeTextEntryProps & import("react").RefAttributes<G9BarcodeTextEntryHandle>>;
|
|
54
|
+
//# sourceMappingURL=barcode-text-entry.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"barcode-text-entry.d.ts","sourceRoot":"","sources":["../src/barcode-text-entry.tsx"],"names":[],"mappings":"AACA,OAAO,EAEL,KAAK,iBAAiB,EACtB,KAAK,gBAAgB,EACrB,KAAK,mBAAmB,EACzB,MAAM,2BAA2B,CAAC;AASnC,OAAO,EAGL,KAAK,iBAAiB,EACtB,KAAK,iBAAiB,EACtB,KAAK,uBAAuB,EAE7B,MAAM,S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AAI,CAAC;IACjB,qFAAqF;IACrF,iBAAiB,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC;IACzC,qGAAqG;IACrG,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC;CACvB;AAED;;;;;GAKG;AACH,eAAO,MAAM,kBAAkB,8HAsM9B,CAAC"}
|
|
@@ -0,0 +1,177 @@
|
|
|
1
|
+
import { useControllableState } from "@g9tm/lynxcontrols/base";
|
|
2
|
+
import { G9TextEntry } from "@g9tm/lynxcontrols/fields";
|
|
3
|
+
import { useG9Diagnostics, useG9OptionalService, useG9Strings } from "@g9tm/lynxcontrols/provider";
|
|
4
|
+
import { G9StringKey, G9TextInputDirection, createAbortController } from "@g9tm/lynxcontrols-foundation";
|
|
5
|
+
import { forwardRef, useEffect, useImperativeHandle, useRef, useState } from "@lynx-js/react";
|
|
6
|
+
import { appendScannedCode, barcodeFieldState, isBarcodeAccepted } from "./model.jsx";
|
|
7
|
+
const barcode_text_entry_G9BarcodeTextEntry = forwardRef(function(props, ref) {
|
|
8
|
+
var _props_defaultValue, _props_defaultScanState, _props_scanBusyText, _props_trailingIcon, _props_className, _props_inputTextDirection;
|
|
9
|
+
const strings = useG9Strings();
|
|
10
|
+
const diagnostics = useG9Diagnostics();
|
|
11
|
+
const scanner = useG9OptionalService('scanner');
|
|
12
|
+
const [text, setText] = useControllableState({
|
|
13
|
+
value: props.value,
|
|
14
|
+
defaultValue: null != (_props_defaultValue = props.defaultValue) ? _props_defaultValue : '',
|
|
15
|
+
onChange: props.onValueChange,
|
|
16
|
+
name: 'G9BarcodeTextEntry.value'
|
|
17
|
+
});
|
|
18
|
+
const [state, setState] = useControllableState({
|
|
19
|
+
value: props.scanState,
|
|
20
|
+
defaultValue: null != (_props_defaultScanState = props.defaultScanState) ? _props_defaultScanState : 'idle',
|
|
21
|
+
onChange: props.onScanStateChange,
|
|
22
|
+
name: 'G9BarcodeTextEntry.scanState'
|
|
23
|
+
});
|
|
24
|
+
const latest = useRef({
|
|
25
|
+
text,
|
|
26
|
+
state,
|
|
27
|
+
props
|
|
28
|
+
});
|
|
29
|
+
latest.current = {
|
|
30
|
+
text,
|
|
31
|
+
state,
|
|
32
|
+
props
|
|
33
|
+
};
|
|
34
|
+
const entry = useRef(null);
|
|
35
|
+
const [scannerAvailable, setScannerAvailable] = useState(false);
|
|
36
|
+
useEffect(()=>{
|
|
37
|
+
if (!scanner) return;
|
|
38
|
+
let live = true;
|
|
39
|
+
scanner.isAvailable().then((available)=>{
|
|
40
|
+
if (live) setScannerAvailable(true === available);
|
|
41
|
+
}, ()=>void 0);
|
|
42
|
+
return ()=>{
|
|
43
|
+
live = false;
|
|
44
|
+
};
|
|
45
|
+
}, [
|
|
46
|
+
scanner
|
|
47
|
+
]);
|
|
48
|
+
const run = useRef({
|
|
49
|
+
generation: 0,
|
|
50
|
+
controller: null
|
|
51
|
+
});
|
|
52
|
+
const abortRun = ()=>{
|
|
53
|
+
var _run_current_controller;
|
|
54
|
+
run.current.generation += 1;
|
|
55
|
+
null == (_run_current_controller = run.current.controller) || _run_current_controller.abort();
|
|
56
|
+
run.current.controller = null;
|
|
57
|
+
};
|
|
58
|
+
useEffect(()=>abortRun, []);
|
|
59
|
+
const setScanState = (next)=>{
|
|
60
|
+
latest.current = {
|
|
61
|
+
...latest.current,
|
|
62
|
+
state: next
|
|
63
|
+
};
|
|
64
|
+
setState(next);
|
|
65
|
+
};
|
|
66
|
+
const startScan = ()=>setScanState('scanBusy');
|
|
67
|
+
const stopScan = ()=>{
|
|
68
|
+
abortRun();
|
|
69
|
+
if ('scanBusy' === latest.current.state) setScanState('idle');
|
|
70
|
+
};
|
|
71
|
+
const acceptScannedCode = (code)=>{
|
|
72
|
+
var _latest_current_props_scanMode;
|
|
73
|
+
var _latest_current_props_onAccepted, _latest_current_props;
|
|
74
|
+
if (!isBarcodeAccepted(code, latest.current.props.acceptedCodeRegex)) {
|
|
75
|
+
setScanState('error');
|
|
76
|
+
return false;
|
|
77
|
+
}
|
|
78
|
+
const next = appendScannedCode(latest.current.text, code, null != (_latest_current_props_scanMode = latest.current.props.scanMode) ? _latest_current_props_scanMode : 'single');
|
|
79
|
+
latest.current = {
|
|
80
|
+
...latest.current,
|
|
81
|
+
text: next
|
|
82
|
+
};
|
|
83
|
+
setText(next, {
|
|
84
|
+
source: 'scan'
|
|
85
|
+
});
|
|
86
|
+
setScanState('accepted');
|
|
87
|
+
null == (_latest_current_props_onAccepted = (_latest_current_props = latest.current.props).onAccepted) || _latest_current_props_onAccepted.call(_latest_current_props, code);
|
|
88
|
+
return true;
|
|
89
|
+
};
|
|
90
|
+
const scan = async ()=>{
|
|
91
|
+
if (!scanner) return;
|
|
92
|
+
abortRun();
|
|
93
|
+
const generation = run.current.generation;
|
|
94
|
+
const controller = createAbortController();
|
|
95
|
+
run.current.controller = controller;
|
|
96
|
+
startScan();
|
|
97
|
+
try {
|
|
98
|
+
for(;;){
|
|
99
|
+
var _latest_current_props_scanMode;
|
|
100
|
+
const formats = latest.current.props.scanFormats;
|
|
101
|
+
const result = await scanner.scan({
|
|
102
|
+
signal: controller.signal,
|
|
103
|
+
...formats ? {
|
|
104
|
+
formats
|
|
105
|
+
} : {}
|
|
106
|
+
});
|
|
107
|
+
if (generation !== run.current.generation) return;
|
|
108
|
+
if ('cancelled' === result.status) return void stopScan();
|
|
109
|
+
if ('denied' === result.status) {
|
|
110
|
+
run.current.controller = null;
|
|
111
|
+
setScanState('error');
|
|
112
|
+
return;
|
|
113
|
+
}
|
|
114
|
+
const accepted = acceptScannedCode(result.text);
|
|
115
|
+
if (!accepted || (null != (_latest_current_props_scanMode = latest.current.props.scanMode) ? _latest_current_props_scanMode : 'single') === 'single') {
|
|
116
|
+
run.current.controller = null;
|
|
117
|
+
return;
|
|
118
|
+
}
|
|
119
|
+
setScanState('scanBusy');
|
|
120
|
+
}
|
|
121
|
+
} catch (error) {
|
|
122
|
+
if (generation !== run.current.generation) return;
|
|
123
|
+
run.current.controller = null;
|
|
124
|
+
setScanState('error');
|
|
125
|
+
diagnostics.log({
|
|
126
|
+
level: 'error',
|
|
127
|
+
message: 'G9BarcodeTextEntry: scan failed.',
|
|
128
|
+
source: 'G9BarcodeTextEntry',
|
|
129
|
+
error
|
|
130
|
+
});
|
|
131
|
+
}
|
|
132
|
+
};
|
|
133
|
+
useImperativeHandle(ref, ()=>{
|
|
134
|
+
const inner = ()=>entry.current;
|
|
135
|
+
return {
|
|
136
|
+
focus: ()=>inner().focus(),
|
|
137
|
+
blur: ()=>inner().blur(),
|
|
138
|
+
validate: ()=>inner().validate(),
|
|
139
|
+
get isListening () {
|
|
140
|
+
return inner().isListening;
|
|
141
|
+
},
|
|
142
|
+
toggleVoice: ()=>inner().toggleVoice(),
|
|
143
|
+
startVoice: ()=>inner().startVoice(),
|
|
144
|
+
stopVoice: ()=>inner().stopVoice(),
|
|
145
|
+
get element () {
|
|
146
|
+
return inner().element;
|
|
147
|
+
},
|
|
148
|
+
startScan,
|
|
149
|
+
stopScan,
|
|
150
|
+
acceptScannedCode,
|
|
151
|
+
scan
|
|
152
|
+
};
|
|
153
|
+
});
|
|
154
|
+
const field = barcodeFieldState(state, {
|
|
155
|
+
hasError: props.hasError,
|
|
156
|
+
readOnly: props.readOnly,
|
|
157
|
+
useStatusColor: props.useStatusColor,
|
|
158
|
+
statusColor: props.statusColor,
|
|
159
|
+
placeholder: props.placeholder,
|
|
160
|
+
isEditable: props.isEditable
|
|
161
|
+
}, null != (_props_scanBusyText = props.scanBusyText) ? _props_scanBusyText : strings.get(G9StringKey.Scanning));
|
|
162
|
+
const actionable = 'idle' === state && (void 0 !== props.onScanRequested || scannerAvailable);
|
|
163
|
+
const trailingIcon = 'accepted' === field.trailing ? 'check' : 'error' === field.trailing ? 'info' : null != (_props_trailingIcon = props.trailingIcon) ? _props_trailingIcon : 'scanCode';
|
|
164
|
+
const { acceptedCodeRegex: _acceptor, scanMode: _mode, isEditable: _editable, scanBusyText: _busyText, scanState: _state, defaultScanState: _defaultState, onScanStateChange: _onState, onScanRequested: _onRequested, onAccepted: _onAccepted, scanFormats: _formats, ...entryProps } = props;
|
|
165
|
+
return <G9TextEntry {...entryProps} ref={entry} className={`g9-barcode g9-barcode--${state} ${null != (_props_className = props.className) ? _props_className : ''}`} value={text} onValueChange={(value, details)=>{
|
|
166
|
+
setText(value, details);
|
|
167
|
+
if ('accepted' === latest.current.state || 'error' === latest.current.state) setScanState('idle');
|
|
168
|
+
}} hasError={field.hasError} readOnly={field.readOnly} useStatusColor={field.useStatusColor} statusColor={field.statusColor} placeholder={field.placeholder} isTrailingBusy={field.isTrailingBusy} trailingIcon={trailingIcon} forceTrailingIconRight inputTextDirection={null != (_props_inputTextDirection = props.inputTextDirection) ? _props_inputTextDirection : G9TextInputDirection.LeftToRight} {...actionable ? {
|
|
169
|
+
onTrailingPress: ()=>{
|
|
170
|
+
if (latest.current.props.onScanRequested) latest.current.props.onScanRequested();
|
|
171
|
+
else scan();
|
|
172
|
+
}
|
|
173
|
+
} : {}}/>;
|
|
174
|
+
});
|
|
175
|
+
export { barcode_text_entry_G9BarcodeTextEntry as G9BarcodeTextEntry };
|
|
176
|
+
|
|
177
|
+
//# sourceMappingURL=barcode-text-entry.jsx.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"barcode-text-entry.jsx","sources":["../src/barcode-text-entry.tsx"],"sourcesContent":["import { useControllableState } from '@g9tm/lynxcontrols/base';\nimport {\n G9TextEntry,\n type G9TextEntryHandle,\n type G9TextEntryProps,\n type G9ValueChangeSource,\n} from '@g9tm/lynxcontrols/fields';\nimport { useG9Diagnostics, useG9OptionalService, useG9Strings } from '@g9tm/lynxcontrols/provider';\nimport {\n createAbortController,\n type G9AbortController,\n G9StringKey,\n G9TextInputDirection,\n} from '@g9tm/lynxcontrols-foundation';\nimport { forwardRef, type ReactNode, useEffect, useImperativeHandle, useRef, useState } from '@lynx-js/react';\nimport {\n appendScannedCode,\n barcodeFieldState,\n type G9BarcodeAcceptor,\n type G9BarcodeScanMode,\n type G9BarcodeTextEntryState,\n isBarcodeAccepted,\n} from './model';\n\n/** Where a barcode field's value change came from: the text-entry sources plus an accepted `'scan'`. */\nexport type G9BarcodeValueSource = G9ValueChangeSource | 'scan';\n\n/** Props of {@link G9BarcodeTextEntry}: every `G9TextEntry` prop plus the scan workflow. */\nexport interface G9BarcodeTextEntryProps\n extends Omit<G9TextEntryProps, 'onTrailingPress' | 'isTrailingBusy' | 'onValueChange'> {\n /** One call per change; `source: 'scan'` for an accepted scanned code. */\n readonly onValueChange?: (value: string, details: { readonly source: G9BarcodeValueSource }) => void;\n /**\n * Codes must match before they are accepted (MAUI `AcceptedCodeRegex`): a pattern string, a `RegExp`, or a function.\n * Unset accepts any code. A malformed pattern or a throwing function rejects the code.\n */\n readonly acceptedCodeRegex?: G9BarcodeAcceptor;\n /** `'single'` (default) replaces the text; `'multiple'` appends `\", code\"` and keeps scanning. */\n readonly scanMode?: G9BarcodeScanMode;\n /** Allow typing as well as scanning (MAUI `IsEditable`). Default false. */\n readonly isEditable?: boolean;\n /** Placeholder while scanning (MAUI `ScanBusyText`). Default: the `Scanning` string. */\n readonly scanBusyText?: string | null;\n /** Controlled scan state (MAUI `ScanState`). */\n readonly scanState?: G9BarcodeTextEntryState;\n readonly defaultScanState?: G9BarcodeTextEntryState;\n readonly onScanStateChange?: (state: G9BarcodeTextEntryState) => void;\n /**\n * The scan icon was tapped (MAUI `ScanRequested`): you own the camera; call `startScan()`, then\n * `acceptScannedCode(code)` and `stopScan()` on the handle. Without it, the field scans through `services.scanner`.\n */\n readonly onScanRequested?: () => void;\n /** A code passed the acceptor (MAUI `Accepted`); never fired for typed text. */\n readonly onAccepted?: (code: string) => void;\n /** Symbologies passed to `services.scanner.scan` (e.g. `['qr', 'code128']`). */\n readonly scanFormats?: readonly string[];\n}\n\n/** Imperative handle: the text-entry handle plus MAUI `StartScan` / `StopScan` / `AcceptScannedCode`. */\nexport interface G9BarcodeTextEntryHandle extends G9TextEntryHandle {\n /** Enters `scanBusy` (MAUI `StartScan`). */\n startScan(): void;\n /** Back to `idle` from `scanBusy`; a scan through `services.scanner` is aborted and its late result ignored. */\n stopScan(): void;\n /** Validates and applies a code; `true` when accepted (MAUI `AcceptScannedCode`). */\n acceptScannedCode(code: string): boolean;\n /** Runs the built-in scan through `services.scanner` (what a tap does without `onScanRequested`). */\n scan(): Promise<void>;\n}\n\n/**\n * A scanner-aware text field (MAUI `G9BarcodeTextEntry`) on `G9TextEntry`: a trailing scan affordance (pinned right,\n * text pinned LTR), idle → spinner → ✓ / ⓘ states layered over your own field values, an acceptor for scanned codes,\n * and single or multiple (comma-joined) collection. The camera is never this package's: either handle\n * `onScanRequested`, or supply `services.scanner` and the field drives it (aborting on `stopScan` and on unmount).\n */\nexport const G9BarcodeTextEntry = forwardRef<G9BarcodeTextEntryHandle, G9BarcodeTextEntryProps>(\n function G9BarcodeTextEntry(props, ref): ReactNode {\n const strings = useG9Strings();\n const diagnostics = useG9Diagnostics();\n const scanner = useG9OptionalService('scanner');\n const [text, setText] = useControllableState<string, [details: { readonly source: G9BarcodeValueSource }]>({\n value: props.value,\n defaultValue: props.defaultValue ?? '',\n onChange: props.onValueChange,\n name: 'G9BarcodeTextEntry.value',\n });\n const [state, setState] = useControllableState<G9BarcodeTextEntryState>({\n value: props.scanState,\n defaultValue: props.defaultScanState ?? 'idle',\n onChange: props.onScanStateChange,\n name: 'G9BarcodeTextEntry.scanState',\n });\n const latest = useRef({ text, state, props });\n latest.current = { text, state, props };\n const entry = useRef<G9TextEntryHandle | null>(null);\n\n // Whether the built-in scanner can run (asked once; no permission prompt).\n const [scannerAvailable, setScannerAvailable] = useState(false);\n useEffect(() => {\n if (!scanner) return;\n let live = true;\n scanner.isAvailable().then(\n (available) => {\n if (live) setScannerAvailable(available === true);\n },\n () => undefined,\n );\n return () => {\n live = false;\n };\n }, [scanner]);\n\n const run = useRef<{ generation: number; controller: G9AbortController | null }>({\n generation: 0,\n controller: null,\n });\n const abortRun = () => {\n run.current.generation += 1;\n run.current.controller?.abort();\n run.current.controller = null;\n };\n useEffect(() => abortRun, []);\n\n const setScanState = (next: G9BarcodeTextEntryState) => {\n latest.current = { ...latest.current, state: next };\n setState(next);\n };\n const startScan = () => setScanState('scanBusy');\n const stopScan = () => {\n abortRun();\n if (latest.current.state === 'scanBusy') setScanState('idle');\n };\n const acceptScannedCode = (code: string): boolean => {\n if (!isBarcodeAccepted(code, latest.current.props.acceptedCodeRegex)) {\n setScanState('error');\n return false;\n }\n const next = appendScannedCode(latest.current.text, code, latest.current.props.scanMode ?? 'single');\n latest.current = { ...latest.current, text: next };\n setText(next, { source: 'scan' });\n setScanState('accepted');\n latest.current.props.onAccepted?.(code);\n return true;\n };\n\n const scan = async (): Promise<void> => {\n if (!scanner) return;\n abortRun();\n const generation = run.current.generation;\n const controller = createAbortController();\n run.current.controller = controller;\n startScan();\n try {\n for (;;) {\n const formats = latest.current.props.scanFormats;\n const result = await scanner.scan({ signal: controller.signal, ...(formats ? { formats } : {}) });\n if (generation !== run.current.generation) return;\n if (result.status === 'cancelled') {\n stopScan();\n return;\n }\n if (result.status === 'denied') {\n run.current.controller = null;\n setScanState('error');\n return;\n }\n const accepted = acceptScannedCode(result.text);\n if (!accepted || (latest.current.props.scanMode ?? 'single') === 'single') {\n run.current.controller = null;\n return;\n }\n // Multiple: stay armed for the next code.\n setScanState('scanBusy');\n }\n } catch (error) {\n if (generation !== run.current.generation) return;\n run.current.controller = null;\n setScanState('error');\n diagnostics.log({\n level: 'error',\n message: 'G9BarcodeTextEntry: scan failed.',\n source: 'G9BarcodeTextEntry',\n error,\n });\n }\n };\n\n useImperativeHandle(ref, () => {\n // The inner entry is mounted whenever this handle is reachable.\n const inner = () => entry.current as G9TextEntryHandle;\n return {\n focus: () => inner().focus(),\n blur: () => inner().blur(),\n validate: () => inner().validate(),\n get isListening() {\n return inner().isListening;\n },\n toggleVoice: () => inner().toggleVoice(),\n startVoice: () => inner().startVoice(),\n stopVoice: () => inner().stopVoice(),\n get element() {\n return inner().element;\n },\n startScan,\n stopScan,\n acceptScannedCode,\n scan,\n };\n });\n\n const field = barcodeFieldState(\n state,\n {\n hasError: props.hasError,\n readOnly: props.readOnly,\n useStatusColor: props.useStatusColor,\n statusColor: props.statusColor,\n placeholder: props.placeholder,\n isEditable: props.isEditable,\n },\n props.scanBusyText ?? strings.get(G9StringKey.Scanning),\n );\n const actionable = state === 'idle' && (props.onScanRequested !== undefined || scannerAvailable);\n const trailingIcon =\n field.trailing === 'accepted'\n ? 'check'\n : field.trailing === 'error'\n ? 'info'\n : (props.trailingIcon ?? 'scanCode');\n const {\n acceptedCodeRegex: _acceptor,\n scanMode: _mode,\n isEditable: _editable,\n scanBusyText: _busyText,\n scanState: _state,\n defaultScanState: _defaultState,\n onScanStateChange: _onState,\n onScanRequested: _onRequested,\n onAccepted: _onAccepted,\n scanFormats: _formats,\n ...entryProps\n } = props;\n return (\n <G9TextEntry\n {...entryProps}\n ref={entry}\n className={`g9-barcode g9-barcode--${state} ${props.className ?? ''}`}\n value={text}\n onValueChange={(value, details) => {\n setText(value, details);\n // Typing after a scan result returns the field to idle (MAUI: until the user types or scans again).\n if (latest.current.state === 'accepted' || latest.current.state === 'error') setScanState('idle');\n }}\n hasError={field.hasError}\n readOnly={field.readOnly}\n useStatusColor={field.useStatusColor}\n statusColor={field.statusColor}\n placeholder={field.placeholder}\n isTrailingBusy={field.isTrailingBusy}\n trailingIcon={trailingIcon}\n forceTrailingIconRight\n inputTextDirection={props.inputTextDirection ?? G9TextInputDirection.LeftToRight}\n {...(actionable\n ? {\n onTrailingPress: () => {\n if (latest.current.props.onScanRequested) latest.current.props.onScanRequested();\n else void scan();\n },\n }\n : {})}\n />\n );\n },\n);\n"],"names":["G9BarcodeTextEntry","forwardRef","props","ref","_props_defaultValue","_props_defaultScanState","_props_scanBusyText","_props_trailingIcon","_props_className","_props_inputTextDirection","strings","useG9Strings","diagnostics","useG9Diagnostics","scanner","useG9OptionalService","text","setText","useControllableState","state","setState","latest","useRef","entry","scannerAvailable","setScannerAvailable","useState","useEffect","live","available","undefined","run","abortRun","_run_current_controller","setScanState","next","startScan","stopScan","acceptScannedCode","code","_latest_current_props_scanMode","_latest_current_props","isBarcodeAccepted","appendScannedCode","scan","generation","controller","createAbortController","formats","result","accepted","error","useImperativeHandle","inner","field","barcodeFieldState","G9StringKey","actionable","trailingIcon","_acceptor","_mode","_editable","_busyText","_state","_defaultState","_onState","_onRequested","_onAccepted","_formats","entryProps","G9TextEntry","value","details","G9TextInputDirection"],"mappings":";;;;;;AA4EO,MAAMA,wCAAqBC,WAChC,SAA4BC,KAAK,EAAEC,GAAG;QAMpBC,qBAMAC,yBAoIdC,qBAQOC,qBAkByCC,kBAe1BC;IAxLxB,MAAMC,UAAUC;IAChB,MAAMC,cAAcC;IACpB,MAAMC,UAAUC,qBAAqB;IACrC,MAAM,CAACC,MAAMC,QAAQ,GAAGC,qBAAmF;QACzG,OAAOhB,MAAM,KAAK;QAClB,cAAc,QAAAE,CAAAA,sBAAAA,MAAM,YAAY,AAAD,IAAjBA,sBAAsB;QACpC,UAAUF,MAAM,aAAa;QAC7B,MAAM;IACR;IACA,MAAM,CAACiB,OAAOC,SAAS,GAAGF,qBAA8C;QACtE,OAAOhB,MAAM,SAAS;QACtB,cAAc,QAAAG,CAAAA,0BAAAA,MAAM,gBAAgB,AAAD,IAArBA,0BAA0B;QACxC,UAAUH,MAAM,iBAAiB;QACjC,MAAM;IACR;IACA,MAAMmB,SAASC,OAAO;QAAEN;QAAMG;QAAOjB;IAAM;IAC3CmB,OAAO,OAAO,GAAG;QAAEL;QAAMG;QAAOjB;IAAM;IACtC,MAAMqB,QAAQD,OAAiC;IAG/C,MAAM,CAACE,kBAAkBC,oBAAoB,GAAGC,SAAS;IACzDC,UAAU;QACR,IAAI,CAACb,SAAS;QACd,IAAIc,OAAO;QACXd,QAAQ,WAAW,GAAG,IAAI,CACxB,CAACe;YACC,IAAID,MAAMH,oBAAoBI,AAAc,SAAdA;QAChC,GACA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BA,OAAO,OAAO,CAAC,KAAK,IAAmBA,AAAyB,YAAzBA,OAAO,OAAO,CAAC,KAAK,EAAca,aAAa;IAC5F,GACA,UAAUoB,MAAM,QAAQ,EACxB,UAAUA,MAAM,QAAQ,EACxB,gBAAgBA,MAAM,cAAc,EACpC,aAAaA,MAAM,WAAW,EAC9B,aAAaA,MAAM,WAAW,EAC9B,gBAAgBA,MAAM,cAAc,EACpC,cAAcI,cACd,uBACA,oBAAoB,QAAAjD,CAAAA,4BAAAA,MAAM,kBAAkB,AAAD,IAAvBA,4BAA4BgE,qBAAqB,WAAW,GAC/E,GAAIhB,aACD;QACE,iBAAiB;YACf,IAAIpC,OAAO,OAAO,CAAC,KAAK,CAAC,eAAe,EAAEA,OAAO,OAAO,CAAC,KAAK,CAAC,eAAe;iBACpEuB;QACZ;IACF,IACA,CAAC,CAAC;AAGZ"}
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
export { G9BarcodeTextEntry, type G9BarcodeTextEntryHandle, type G9BarcodeTextEntryProps, type G9BarcodeValueSource, } from './barcode-text-entry.js';
|
|
2
|
+
export { appendScannedCode, barcodeFieldState, type G9BarcodeAcceptor, type G9BarcodeConsumerField, type G9BarcodeFieldState, type G9BarcodeScanMode, type G9BarcodeTextEntryState, g9BarcodeMaxCodeLength, isBarcodeAccepted, } from './model.js';
|
|
3
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,kBAAkB,EAClB,KAAK,wBAAwB,EAC7B,KAAK,uBAAuB,EAC5B,KAAK,oBAAoB,GAC1B,MAAM,sBAAsB,CAAC;AAC9B,OAAO,EACL,iBAAiB,EACjB,iBAAiB,EACjB,KAAK,iBAAiB,EACtB,KAAK,sBAAsB,EAC3B,KAAK,mBAAmB,EACxB,KAAK,iBAAiB,EACtB,KAAK,uBAAuB,EAC5B,sBAAsB,EACtB,iBAAiB,GAClB,MAAM,SAAS,CAAC"}
|
package/dist/index.jsx
ADDED
package/dist/model.d.ts
ADDED
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
/** Whether the field keeps one code or collects many (MAUI `G9BarcodeScanMode`). */
|
|
2
|
+
export type G9BarcodeScanMode = 'single' | 'multiple';
|
|
3
|
+
/** The scan state, tracked apart from the field's own error (MAUI `G9BarcodeTextEntryState`). */
|
|
4
|
+
export type G9BarcodeTextEntryState = 'idle' | 'scanBusy' | 'accepted' | 'error';
|
|
5
|
+
/** Codes longer than this are rejected before any pattern runs, so a consumer pattern never sees unbounded input. */
|
|
6
|
+
export declare const g9BarcodeMaxCodeLength = 4096;
|
|
7
|
+
/** A code acceptor: a pattern (string or `RegExp`), or a function the app supplies. */
|
|
8
|
+
export type G9BarcodeAcceptor = string | RegExp | ((code: string) => boolean) | null | undefined;
|
|
9
|
+
/**
|
|
10
|
+
* Whether a scanned code is accepted (MAUI `IsCodeAccepted`): no acceptor accepts any code; a malformed pattern or a
|
|
11
|
+
* throwing function rejects it instead of throwing into the scan flow. A code over {@link g9BarcodeMaxCodeLength}
|
|
12
|
+
* characters is rejected (MAUI bounded the match with a 250 ms regex timeout, which JavaScript cannot do).
|
|
13
|
+
*/
|
|
14
|
+
export declare function isBarcodeAccepted(code: string, acceptor: G9BarcodeAcceptor): boolean;
|
|
15
|
+
/** The text after accepting `code` (MAUI: `Single` replaces, `Multiple` appends with `", "`). */
|
|
16
|
+
export declare function appendScannedCode(text: string, code: string, mode: G9BarcodeScanMode): string;
|
|
17
|
+
/** What the consumer set on the borrowed field properties. */
|
|
18
|
+
export interface G9BarcodeConsumerField {
|
|
19
|
+
readonly hasError?: boolean | undefined;
|
|
20
|
+
readonly readOnly?: boolean | undefined;
|
|
21
|
+
readonly useStatusColor?: boolean | undefined;
|
|
22
|
+
readonly statusColor?: string | null | undefined;
|
|
23
|
+
readonly placeholder?: string | null | undefined;
|
|
24
|
+
readonly isEditable?: boolean | undefined;
|
|
25
|
+
}
|
|
26
|
+
/** The field properties a scan state layers over the consumer's values (MAUI `ApplyBarcodeState`). */
|
|
27
|
+
export interface G9BarcodeFieldState {
|
|
28
|
+
readonly hasError: boolean;
|
|
29
|
+
readonly readOnly: boolean;
|
|
30
|
+
readonly useStatusColor: boolean;
|
|
31
|
+
readonly statusColor: string | null;
|
|
32
|
+
readonly placeholder: string | null;
|
|
33
|
+
readonly isTrailingBusy: boolean;
|
|
34
|
+
/** The trailing glyph: `'scan'` (consumer icon or the scan glyph), `'accepted'` or `'error'`. */
|
|
35
|
+
readonly trailing: 'scan' | 'accepted' | 'error';
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* Effective field values for a scan state (the MAUI table): error forces `hasError`; not editable or busy forces
|
|
39
|
+
* read-only; busy / accepted force the status colour (primary / success); busy swaps the placeholder for
|
|
40
|
+
* `scanBusyText` and shows a spinner; accepted / error swap the trailing glyph. Everything else is the consumer's.
|
|
41
|
+
*/
|
|
42
|
+
export declare function barcodeFieldState(state: G9BarcodeTextEntryState, consumer: G9BarcodeConsumerField, scanBusyText: string): G9BarcodeFieldState;
|
|
43
|
+
//# sourceMappingURL=model.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"model.d.ts","sourceRoot":"","sources":["../src/model.ts"],"names":[],"mappings":"AAAA,oFAAoF;AACpF,MAAM,MAAM,iBAAiB,GAAG,QAAQ,GAAG,UAAU,CAAC;AAEtD,iGAAiG;AACjG,MAAM,MAAM,uBAAuB,GAAG,MAAM,GAAG,UAAU,GAAG,UAAU,GAAG,OAAO,CAAC;AAEjF,qHAAqH;AACrH,eAAO,MAAM,sBAAsB,OAAO,CAAC;AAE3C,uFAAuF;AACvF,MAAM,MAAM,iBAAiB,GAAG,MAAM,GAAG,MAAM,GAAG,CAAC,CAAC,IAAI,EAAE,MAAM,KAAK,OAAO,CAAC,GAAG,IAAI,GAAG,SAAS,C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mB,CAYrB"}
|
package/dist/model.jsx
ADDED
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
const g9BarcodeMaxCodeLength = 4096;
|
|
2
|
+
function isBarcodeAccepted(code, acceptor) {
|
|
3
|
+
if (code.length > g9BarcodeMaxCodeLength) return false;
|
|
4
|
+
if (null == acceptor || 'string' == typeof acceptor && '' === acceptor.trim()) return true;
|
|
5
|
+
try {
|
|
6
|
+
if ('function' == typeof acceptor) return true === acceptor(code);
|
|
7
|
+
const pattern = 'string' == typeof acceptor ? new RegExp(acceptor) : new RegExp(acceptor.source, acceptor.flags.replace('g', ''));
|
|
8
|
+
return pattern.test(code);
|
|
9
|
+
} catch {
|
|
10
|
+
return false;
|
|
11
|
+
}
|
|
12
|
+
}
|
|
13
|
+
function appendScannedCode(text, code, mode) {
|
|
14
|
+
return 'multiple' === mode && '' !== text.trim() ? `${text}, ${code}` : code;
|
|
15
|
+
}
|
|
16
|
+
function barcodeFieldState(state, consumer, scanBusyText) {
|
|
17
|
+
var _consumer_statusColor, _consumer_placeholder;
|
|
18
|
+
const busy = 'scanBusy' === state;
|
|
19
|
+
const accepted = 'accepted' === state;
|
|
20
|
+
return {
|
|
21
|
+
hasError: 'error' === state || true === consumer.hasError,
|
|
22
|
+
readOnly: true !== consumer.isEditable || busy || true === consumer.readOnly,
|
|
23
|
+
useStatusColor: busy || accepted || true === consumer.useStatusColor,
|
|
24
|
+
statusColor: accepted ? 'var(--g9-success)' : busy ? 'var(--g9-primary)' : null != (_consumer_statusColor = consumer.statusColor) ? _consumer_statusColor : null,
|
|
25
|
+
placeholder: busy ? scanBusyText : null != (_consumer_placeholder = consumer.placeholder) ? _consumer_placeholder : null,
|
|
26
|
+
isTrailingBusy: busy,
|
|
27
|
+
trailing: accepted ? 'accepted' : 'error' === state ? 'error' : 'scan'
|
|
28
|
+
};
|
|
29
|
+
}
|
|
30
|
+
export { appendScannedCode, barcodeFieldState, g9BarcodeMaxCodeLength, isBarcodeAccepted };
|
|
31
|
+
|
|
32
|
+
//# sourceMappingURL=model.jsx.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"model.jsx","sources":["../src/model.ts"],"sourcesContent":["/** Whether the field keeps one code or collects many (MAUI `G9BarcodeScanMode`). */\nexport type G9BarcodeScanMode = 'single' | 'multiple';\n\n/** The scan state, tracked apart from the field's own error (MAUI `G9BarcodeTextEntryState`). */\nexport type G9BarcodeTextEntryState = 'idle' | 'scanBusy' | 'accepted' | 'error';\n\n/** Codes longer than this are rejected before any pattern runs, so a consumer pattern never sees unbounded input. */\nexport const g9BarcodeMaxCodeLength = 4096;\n\n/** A code acceptor: a pattern (string or `RegExp`), or a function the app supplies. */\nexport type G9BarcodeAcceptor = string | RegExp | ((code: string) => boolean) | null | undefined;\n\n/**\n * Whether a scanned code is accepted (MAUI `IsCodeAccepted`): no acceptor accepts any code; a malformed pattern or a\n * throwing function rejects it instead of throwing into the scan flow. A code over {@link g9BarcodeMaxCodeLength}\n * characters is rejected (MAUI bounded the match with a 250 ms regex timeout, which JavaScript cannot do).\n */\nexport function isBarcodeAccepted(code: string, acceptor: G9BarcodeAcceptor): boolean {\n if (code.length > g9BarcodeMaxCodeLength) return false;\n if (acceptor == null || (typeof acceptor === 'string' && acceptor.trim() === '')) return true;\n try {\n if (typeof acceptor === 'function') return acceptor(code) === true;\n const pattern =\n typeof acceptor === 'string'\n ? new RegExp(acceptor)\n : new RegExp(acceptor.source, acceptor.flags.replace('g', ''));\n return pattern.test(code);\n } catch {\n return false;\n }\n}\n\n/** The text after accepting `code` (MAUI: `Single` replaces, `Multiple` appends with `\", \"`). */\nexport function appendScannedCode(text: string, code: string, mode: G9BarcodeScanMode): string {\n return mode === 'multiple' && text.trim() !== '' ? `${text}, ${code}` : code;\n}\n\n/** What the consumer set on the borrowed field properties. */\nexport interface G9BarcodeConsumerField {\n readonly hasError?: boolean | undefined;\n readonly readOnly?: boolean | undefined;\n readonly useStatusColor?: boolean | undefined;\n readonly statusColor?: string | null | undefined;\n readonly placeholder?: string | null | undefined;\n readonly isEditable?: boolean | undefined;\n}\n\n/** The field properties a scan state layers over the consumer's values (MAUI `ApplyBarcodeState`). */\nexport interface G9BarcodeFieldState {\n readonly hasError: boolean;\n readonly readOnly: boolean;\n readonly useStatusColor: boolean;\n readonly statusColor: string | null;\n readonly placeholder: string | null;\n readonly isTrailingBusy: boolean;\n /** The trailing glyph: `'scan'` (consumer icon or the scan glyph), `'accepted'` or `'error'`. */\n readonly trailing: 'scan' | 'accepted' | 'error';\n}\n\n/**\n * Effective field values for a scan state (the MAUI table): error forces `hasError`; not editable or busy forces\n * read-only; busy / accepted force the status colour (primary / success); busy swaps the placeholder for\n * `scanBusyText` and shows a spinner; accepted / error swap the trailing glyph. Everything else is the consumer's.\n */\nexport function barcodeFieldState(\n state: G9BarcodeTextEntryState,\n consumer: G9BarcodeConsumerField,\n scanBusyText: string,\n): G9BarcodeFieldState {\n const busy = state === 'scanBusy';\n const accepted = state === 'accepted';\n return {\n hasError: state === 'error' || consumer.hasError === true,\n readOnly: consumer.isEditable !== true || busy || consumer.readOnly === true,\n useStatusColor: busy || accepted || consumer.useStatusColor === true,\n statusColor: accepted ? 'var(--g9-success)' : busy ? 'var(--g9-primary)' : (consumer.statusColor ?? null),\n placeholder: busy ? scanBusyText : (consumer.placeholder ?? null),\n isTrailingBusy: busy,\n trailing: accepted ? 'accepted' : state === 'error' ? 'error' : 'scan',\n };\n}\n"],"names":["g9BarcodeMaxCodeLength","isBarcodeAccepted","code","acceptor","pattern","RegExp","appendScannedCode","text","mode","barcodeFieldState","state","consumer","scanBusyText","_consumer_statusColor","_consumer_placeholder","busy","accepted"],"mappings":"AAOO,MAAMA,yBAAyB;AAU/B,SAASC,kBAAkBC,IAAY,EAAEC,QAA2B;IACzE,IAAID,KAAK,MAAM,GAAGF,wBAAwB,OAAO;IACjD,IAAIG,AAAY,QAAZA,YAAqB,AAAoB,YAApB,OAAOA,YAAyBA,AAAoB,OAApBA,SAAS,IAAI,I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"
|
|
6
|
-
|
|
3
|
+
"version": "1.4.2",
|
|
4
|
+
"description": "G9BarcodeTextEntry: a scanner-aware text field. The scanner is consumer-provided (no camera dependency).",
|
|
5
|
+
"license": "MIT",
|
|
6
|
+
"type": "module",
|
|
7
|
+
"sideEffects": [
|
|
8
|
+
"**/*.css"
|
|
9
|
+
],
|
|
10
|
+
"exports": {
|
|
11
|
+
".": {
|
|
12
|
+
"source": "./src/index.ts",
|
|
13
|
+
"types": "./dist/index.d.ts",
|
|
14
|
+
"default": "./dist/index.jsx"
|
|
15
|
+
}
|
|
16
|
+
},
|
|
17
|
+
"files": [
|
|
18
|
+
"dist",
|
|
19
|
+
"README.md"
|
|
20
|
+
],
|
|
21
|
+
"scripts": {
|
|
22
|
+
"build": "rslib build"
|
|
23
|
+
},
|
|
24
|
+
"dependencies": {
|
|
25
|
+
"@g9tm/lynxcontrols-foundation": "1.4.2",
|
|
26
|
+
"@g9tm/lynxcontrols": "1.4.2"
|
|
27
|
+
},
|
|
28
|
+
"peerDependencies": {
|
|
29
|
+
"@lynx-js/react": ">=0.126.2 <0.127.0"
|
|
30
|
+
}
|
|
31
|
+
}
|