@angular-helpers/browser-web-apis 21.2.0 → 21.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@angular-helpers/browser-web-apis",
3
- "version": "21.2.0",
3
+ "version": "21.3.0",
4
4
  "description": "Sistema de servicios Angular para acceso formalizado a Browser Web APIs (cámara, permisos, geolocalización, etc.)",
5
5
  "keywords": [
6
6
  "angular",
@@ -1,6 +1,6 @@
1
1
  import { Observable } from 'rxjs';
2
2
  import * as i0 from '@angular/core';
3
- import { DestroyRef, Signal, ElementRef, EnvironmentProviders } from '@angular/core';
3
+ import { DestroyRef, ElementRef, Signal, EnvironmentProviders } from '@angular/core';
4
4
  import { CanActivateFn } from '@angular/router';
5
5
 
6
6
  type PermissionNameExt = PermissionName | 'clipboard-read' | 'clipboard-write';
@@ -126,7 +126,7 @@ declare class ClipboardService extends BrowserApiBaseService {
126
126
  static ɵprov: i0.ɵɵInjectableDeclaration<ClipboardService>;
127
127
  }
128
128
 
129
- type BrowserCapabilityId = 'permissions' | 'geolocation' | 'clipboard' | 'notification' | 'mediaDevices' | 'camera' | 'webWorker' | 'regexSecurity' | 'webStorage' | 'webShare' | 'battery' | 'webSocket' | 'intersectionObserver' | 'resizeObserver' | 'pageVisibility' | 'broadcastChannel' | 'networkInformation' | 'screenWakeLock' | 'screenOrientation' | 'fullscreen' | 'fileSystemAccess' | 'mediaRecorder' | 'serverSentEvents' | 'vibration' | 'speechSynthesis';
129
+ type BrowserCapabilityId = 'permissions' | 'geolocation' | 'clipboard' | 'notification' | 'mediaDevices' | 'camera' | 'webWorker' | 'regexSecurity' | 'webStorage' | 'webShare' | 'battery' | 'webSocket' | 'intersectionObserver' | 'resizeObserver' | 'pageVisibility' | 'broadcastChannel' | 'networkInformation' | 'screenWakeLock' | 'screenOrientation' | 'fullscreen' | 'fileSystemAccess' | 'mediaRecorder' | 'serverSentEvents' | 'vibration' | 'speechSynthesis' | 'mutationObserver' | 'performanceObserver' | 'idleDetector' | 'eyeDropper' | 'barcodeDetector' | 'webAudio' | 'gamepad' | 'webBluetooth' | 'webUsb' | 'webNfc' | 'paymentRequest' | 'credentialManagement';
130
130
  declare class BrowserCapabilityService {
131
131
  getCapabilities(): readonly [{
132
132
  readonly id: "permissions";
@@ -228,12 +228,60 @@ declare class BrowserCapabilityService {
228
228
  readonly id: "speechSynthesis";
229
229
  readonly label: "Speech Synthesis API";
230
230
  readonly requiresSecureContext: false;
231
+ }, {
232
+ readonly id: "mutationObserver";
233
+ readonly label: "Mutation Observer";
234
+ readonly requiresSecureContext: false;
235
+ }, {
236
+ readonly id: "performanceObserver";
237
+ readonly label: "Performance Observer";
238
+ readonly requiresSecureContext: false;
239
+ }, {
240
+ readonly id: "idleDetector";
241
+ readonly label: "Idle Detection API";
242
+ readonly requiresSecureContext: true;
243
+ }, {
244
+ readonly id: "eyeDropper";
245
+ readonly label: "EyeDropper API";
246
+ readonly requiresSecureContext: true;
247
+ }, {
248
+ readonly id: "barcodeDetector";
249
+ readonly label: "Barcode Detection API";
250
+ readonly requiresSecureContext: true;
251
+ }, {
252
+ readonly id: "webAudio";
253
+ readonly label: "Web Audio API";
254
+ readonly requiresSecureContext: false;
255
+ }, {
256
+ readonly id: "gamepad";
257
+ readonly label: "Gamepad API";
258
+ readonly requiresSecureContext: true;
259
+ }, {
260
+ readonly id: "webBluetooth";
261
+ readonly label: "Web Bluetooth API";
262
+ readonly requiresSecureContext: true;
263
+ }, {
264
+ readonly id: "webUsb";
265
+ readonly label: "WebUSB API";
266
+ readonly requiresSecureContext: true;
267
+ }, {
268
+ readonly id: "webNfc";
269
+ readonly label: "Web NFC API";
270
+ readonly requiresSecureContext: true;
271
+ }, {
272
+ readonly id: "paymentRequest";
273
+ readonly label: "Payment Request API";
274
+ readonly requiresSecureContext: true;
275
+ }, {
276
+ readonly id: "credentialManagement";
277
+ readonly label: "Credential Management API";
278
+ readonly requiresSecureContext: true;
231
279
  }];
232
280
  isSecureContext(): boolean;
233
281
  isSupported(capability: BrowserCapabilityId): boolean;
234
282
  getAllStatuses(): {
235
- id: "camera" | "geolocation" | "permissions" | "mediaDevices" | "clipboard" | "notification" | "webWorker" | "regexSecurity" | "webStorage" | "webShare" | "battery" | "webSocket" | "intersectionObserver" | "resizeObserver" | "pageVisibility" | "broadcastChannel" | "networkInformation" | "screenWakeLock" | "screenOrientation" | "fullscreen" | "fileSystemAccess" | "mediaRecorder" | "serverSentEvents" | "vibration" | "speechSynthesis";
236
- label: "Permissions API" | "Geolocation API" | "Clipboard API" | "Notification API" | "MediaDevices API" | "Camera API" | "Web Worker API" | "Regex Security" | "Web Storage" | "Web Share" | "Battery API" | "WebSocket API" | "Intersection Observer" | "Resize Observer" | "Page Visibility API" | "Broadcast Channel API" | "Network Information API" | "Screen Wake Lock API" | "Screen Orientation API" | "Fullscreen API" | "File System Access API" | "MediaRecorder API" | "Server-Sent Events" | "Vibration API" | "Speech Synthesis API";
283
+ id: "camera" | "geolocation" | "permissions" | "mediaDevices" | "clipboard" | "notification" | "webWorker" | "regexSecurity" | "webStorage" | "webShare" | "battery" | "webSocket" | "intersectionObserver" | "resizeObserver" | "pageVisibility" | "broadcastChannel" | "networkInformation" | "screenWakeLock" | "screenOrientation" | "fullscreen" | "fileSystemAccess" | "mediaRecorder" | "serverSentEvents" | "vibration" | "speechSynthesis" | "mutationObserver" | "performanceObserver" | "idleDetector" | "eyeDropper" | "barcodeDetector" | "webAudio" | "gamepad" | "webBluetooth" | "webUsb" | "webNfc" | "paymentRequest" | "credentialManagement";
284
+ label: "Permissions API" | "Geolocation API" | "Clipboard API" | "Notification API" | "MediaDevices API" | "Camera API" | "Web Worker API" | "Regex Security" | "Web Storage" | "Web Share" | "Battery API" | "WebSocket API" | "Intersection Observer" | "Resize Observer" | "Page Visibility API" | "Broadcast Channel API" | "Network Information API" | "Screen Wake Lock API" | "Screen Orientation API" | "Fullscreen API" | "File System Access API" | "MediaRecorder API" | "Server-Sent Events" | "Vibration API" | "Speech Synthesis API" | "Mutation Observer" | "Performance Observer" | "Idle Detection API" | "EyeDropper API" | "Barcode Detection API" | "Web Audio API" | "Gamepad API" | "Web Bluetooth API" | "WebUSB API" | "Web NFC API" | "Payment Request API" | "Credential Management API";
237
285
  supported: boolean;
238
286
  secureContext: boolean;
239
287
  requiresSecureContext: boolean;
@@ -308,6 +356,11 @@ type BrowserError = Error & {
308
356
  type EventHandler<T = Event> = (event: T) => void;
309
357
  type StorageValue = string | number | boolean | object | null;
310
358
  type ErrorCallback = (error: BrowserError) => void;
359
+ /**
360
+ * Accepted element input for inject functions.
361
+ * Supports static elements, ElementRef, or deferred signals (e.g. from viewChild).
362
+ */
363
+ type ElementInput = Element | ElementRef<Element> | Signal<Element | ElementRef<Element> | undefined>;
311
364
 
312
365
  interface StorageOptions {
313
366
  prefix?: string;
@@ -711,6 +764,360 @@ declare class SpeechSynthesisService {
711
764
  static ɵprov: i0.ɵɵInjectableDeclaration<SpeechSynthesisService>;
712
765
  }
713
766
 
767
+ interface MutationObserverOptions {
768
+ childList?: boolean;
769
+ attributes?: boolean;
770
+ characterData?: boolean;
771
+ subtree?: boolean;
772
+ attributeOldValue?: boolean;
773
+ characterDataOldValue?: boolean;
774
+ attributeFilter?: string[];
775
+ }
776
+
777
+ declare class MutationObserverService {
778
+ private readonly platformId;
779
+ isSupported(): boolean;
780
+ observe(target: Node, options?: MutationObserverOptions): Observable<MutationRecord[]>;
781
+ static ɵfac: i0.ɵɵFactoryDeclaration<MutationObserverService, never>;
782
+ static ɵprov: i0.ɵɵInjectableDeclaration<MutationObserverService>;
783
+ }
784
+
785
+ type PerformanceEntryType = 'element' | 'event' | 'first-input' | 'largest-contentful-paint' | 'layout-shift' | 'longtask' | 'mark' | 'measure' | 'navigation' | 'paint' | 'resource' | 'visibility-state';
786
+ interface PerformanceObserverConfig {
787
+ entryTypes?: PerformanceEntryType[];
788
+ type?: PerformanceEntryType;
789
+ buffered?: boolean;
790
+ }
791
+
792
+ declare class PerformanceObserverService {
793
+ private readonly platformId;
794
+ isSupported(): boolean;
795
+ observe(config: PerformanceObserverConfig): Observable<PerformanceEntryList>;
796
+ observeByType(type: PerformanceEntryType, buffered?: boolean): Observable<PerformanceEntryList>;
797
+ getSupportedEntryTypes(): PerformanceEntryType[];
798
+ static ɵfac: i0.ɵɵFactoryDeclaration<PerformanceObserverService, never>;
799
+ static ɵprov: i0.ɵɵInjectableDeclaration<PerformanceObserverService>;
800
+ }
801
+
802
+ type UserIdleState = 'active' | 'idle';
803
+ type ScreenIdleState = 'locked' | 'unlocked';
804
+ interface IdleState {
805
+ user: UserIdleState;
806
+ screen: ScreenIdleState;
807
+ }
808
+ interface IdleDetectorOptions {
809
+ threshold?: number;
810
+ }
811
+ declare class IdleDetectorService {
812
+ private readonly platformId;
813
+ isSupported(): boolean;
814
+ requestPermission(): Promise<PermissionState>;
815
+ watch(options?: IdleDetectorOptions): Observable<IdleState>;
816
+ static ɵfac: i0.ɵɵFactoryDeclaration<IdleDetectorService, never>;
817
+ static ɵprov: i0.ɵɵInjectableDeclaration<IdleDetectorService>;
818
+ }
819
+
820
+ interface ColorSelectionResult {
821
+ sRGBHex: string;
822
+ }
823
+ declare class EyeDropperService {
824
+ private readonly platformId;
825
+ isSupported(): boolean;
826
+ open(signal?: AbortSignal): Promise<ColorSelectionResult>;
827
+ static ɵfac: i0.ɵɵFactoryDeclaration<EyeDropperService, never>;
828
+ static ɵprov: i0.ɵɵInjectableDeclaration<EyeDropperService>;
829
+ }
830
+
831
+ type BarcodeFormat = 'aztec' | 'code_128' | 'code_39' | 'code_93' | 'codabar' | 'data_matrix' | 'ean_13' | 'ean_8' | 'itf' | 'pdf417' | 'qr_code' | 'upc_a' | 'upc_e' | 'unknown';
832
+ interface DetectedBarcode {
833
+ boundingBox: DOMRectReadOnly;
834
+ cornerPoints: ReadonlyArray<{
835
+ x: number;
836
+ y: number;
837
+ }>;
838
+ format: BarcodeFormat;
839
+ rawValue: string;
840
+ }
841
+ declare class BarcodeDetectorService {
842
+ private readonly platformId;
843
+ isSupported(): boolean;
844
+ getSupportedFormats(): Promise<BarcodeFormat[]>;
845
+ detect(image: ImageBitmapSource, formats?: BarcodeFormat[]): Promise<DetectedBarcode[]>;
846
+ static ɵfac: i0.ɵɵFactoryDeclaration<BarcodeDetectorService, never>;
847
+ static ɵprov: i0.ɵɵInjectableDeclaration<BarcodeDetectorService>;
848
+ }
849
+
850
+ type AudioContextState = 'suspended' | 'running' | 'closed';
851
+ interface AudioAnalyserData {
852
+ frequencyData: Uint8Array;
853
+ timeDomainData: Uint8Array;
854
+ }
855
+ declare class WebAudioService {
856
+ private readonly platformId;
857
+ private readonly destroyRef;
858
+ private context;
859
+ isSupported(): boolean;
860
+ getContext(): AudioContext;
861
+ resume(): Promise<void>;
862
+ close(): Promise<void>;
863
+ getState(): AudioContextState;
864
+ createOscillator(type?: OscillatorType, frequency?: number): OscillatorNode;
865
+ createGain(value?: number): GainNode;
866
+ createAnalyser(fftSize?: number): AnalyserNode;
867
+ watchAnalyser(analyser: AnalyserNode, intervalMs?: number): Observable<AudioAnalyserData>;
868
+ decodeAudioData(arrayBuffer: ArrayBuffer): Promise<AudioBuffer>;
869
+ playBuffer(buffer: AudioBuffer, loop?: boolean): AudioBufferSourceNode;
870
+ static ɵfac: i0.ɵɵFactoryDeclaration<WebAudioService, never>;
871
+ static ɵprov: i0.ɵɵInjectableDeclaration<WebAudioService>;
872
+ }
873
+
874
+ interface GamepadState {
875
+ id: string;
876
+ index: number;
877
+ connected: boolean;
878
+ buttons: ReadonlyArray<{
879
+ pressed: boolean;
880
+ value: number;
881
+ }>;
882
+ axes: readonly number[];
883
+ timestamp: number;
884
+ }
885
+
886
+ declare class GamepadService {
887
+ private readonly platformId;
888
+ isSupported(): boolean;
889
+ getSnapshot(index: number): GamepadState | null;
890
+ getConnectedGamepads(): GamepadState[];
891
+ watchConnections(): Observable<{
892
+ gamepad: GamepadState;
893
+ type: 'connected' | 'disconnected';
894
+ }>;
895
+ poll(index: number, intervalMs?: number): Observable<GamepadState>;
896
+ static ɵfac: i0.ɵɵFactoryDeclaration<GamepadService, never>;
897
+ static ɵprov: i0.ɵɵInjectableDeclaration<GamepadService>;
898
+ }
899
+
900
+ interface BluetoothRequestDeviceOptions {
901
+ filters?: Array<{
902
+ services?: string[];
903
+ name?: string;
904
+ namePrefix?: string;
905
+ }>;
906
+ optionalServices?: string[];
907
+ acceptAllDevices?: boolean;
908
+ }
909
+ interface BluetoothRemoteGATTServer {
910
+ readonly connected: boolean;
911
+ readonly device: BluetoothDeviceRef;
912
+ connect(): Promise<BluetoothRemoteGATTServer>;
913
+ disconnect(): void;
914
+ getPrimaryService(service: string): Promise<BluetoothRemoteGATTService>;
915
+ }
916
+ interface BluetoothRemoteGATTService {
917
+ getCharacteristic(characteristic: string): Promise<BluetoothRemoteGATTCharacteristic>;
918
+ }
919
+ interface BluetoothRemoteGATTCharacteristic extends EventTarget {
920
+ readonly value: DataView | null;
921
+ readValue(): Promise<DataView>;
922
+ writeValue(value: BufferSource): Promise<void>;
923
+ startNotifications(): Promise<BluetoothRemoteGATTCharacteristic>;
924
+ stopNotifications(): Promise<BluetoothRemoteGATTCharacteristic>;
925
+ }
926
+ interface BluetoothDeviceRef extends EventTarget {
927
+ readonly id: string;
928
+ readonly name: string | undefined;
929
+ readonly gatt: BluetoothRemoteGATTServer | undefined;
930
+ }
931
+ interface UsbDeviceRef {
932
+ readonly vendorId: number;
933
+ readonly productId: number;
934
+ readonly productName: string | undefined;
935
+ readonly manufacturerName: string | undefined;
936
+ readonly serialNumber: string | undefined;
937
+ readonly opened: boolean;
938
+ open(): Promise<void>;
939
+ close(): Promise<void>;
940
+ selectConfiguration(configurationValue: number): Promise<void>;
941
+ claimInterface(interfaceNumber: number): Promise<void>;
942
+ releaseInterface(interfaceNumber: number): Promise<void>;
943
+ transferIn(endpointNumber: number, length: number): Promise<UsbTransferResult>;
944
+ transferOut(endpointNumber: number, data: BufferSource): Promise<UsbTransferResult>;
945
+ }
946
+ interface UsbTransferResult {
947
+ readonly data: DataView | undefined;
948
+ readonly status: 'ok' | 'stall' | 'babble';
949
+ }
950
+ interface UsbDeviceFilterDef {
951
+ vendorId?: number;
952
+ productId?: number;
953
+ classCode?: number;
954
+ subclassCode?: number;
955
+ protocolCode?: number;
956
+ serialNumber?: string;
957
+ }
958
+ interface NdefMessage {
959
+ records: NdefRecord[];
960
+ }
961
+ interface NdefRecord {
962
+ recordType: string;
963
+ mediaType?: string;
964
+ id?: string;
965
+ data?: DataView;
966
+ encoding?: string;
967
+ lang?: string;
968
+ }
969
+ interface NdefReadingEvent {
970
+ serialNumber: string;
971
+ message: NdefMessage;
972
+ }
973
+ interface NdefWriteOptions {
974
+ overwrite?: boolean;
975
+ signal?: AbortSignal;
976
+ }
977
+
978
+ interface BluetoothDeviceInfo {
979
+ id: string;
980
+ name: string | undefined;
981
+ connected: boolean;
982
+ }
983
+ declare class WebBluetoothService {
984
+ private readonly platformId;
985
+ isSupported(): boolean;
986
+ requestDevice(options?: BluetoothRequestDeviceOptions): Promise<BluetoothDeviceRef>;
987
+ connect(device: BluetoothDeviceRef): Promise<BluetoothRemoteGATTServer>;
988
+ disconnect(device: BluetoothDeviceRef): void;
989
+ watchDisconnection(device: BluetoothDeviceRef): Observable<void>;
990
+ readCharacteristic(server: BluetoothRemoteGATTServer, serviceUuid: string, characteristicUuid: string): Promise<DataView>;
991
+ writeCharacteristic(server: BluetoothRemoteGATTServer, serviceUuid: string, characteristicUuid: string, value: BufferSource): Promise<void>;
992
+ watchCharacteristic(server: BluetoothRemoteGATTServer, serviceUuid: string, characteristicUuid: string): Observable<DataView>;
993
+ static ɵfac: i0.ɵɵFactoryDeclaration<WebBluetoothService, never>;
994
+ static ɵprov: i0.ɵɵInjectableDeclaration<WebBluetoothService>;
995
+ }
996
+
997
+ interface UsbDeviceInfo {
998
+ vendorId: number;
999
+ productId: number;
1000
+ productName: string | undefined;
1001
+ manufacturerName: string | undefined;
1002
+ serialNumber: string | undefined;
1003
+ opened: boolean;
1004
+ }
1005
+ declare class WebUsbService {
1006
+ private readonly platformId;
1007
+ isSupported(): boolean;
1008
+ requestDevice(filters?: UsbDeviceFilterDef[]): Promise<UsbDeviceRef>;
1009
+ getDevices(): Promise<UsbDeviceRef[]>;
1010
+ open(device: UsbDeviceRef): Promise<void>;
1011
+ close(device: UsbDeviceRef): Promise<void>;
1012
+ selectConfiguration(device: UsbDeviceRef, configurationValue: number): Promise<void>;
1013
+ claimInterface(device: UsbDeviceRef, interfaceNumber: number): Promise<void>;
1014
+ releaseInterface(device: UsbDeviceRef, interfaceNumber: number): Promise<void>;
1015
+ transferIn(device: UsbDeviceRef, endpointNumber: number, length: number): Promise<UsbTransferResult>;
1016
+ transferOut(device: UsbDeviceRef, endpointNumber: number, data: BufferSource): Promise<UsbTransferResult>;
1017
+ watchConnection(): Observable<{
1018
+ device: UsbDeviceRef;
1019
+ type: 'connect' | 'disconnect';
1020
+ }>;
1021
+ getDeviceInfo(device: UsbDeviceRef): UsbDeviceInfo;
1022
+ static ɵfac: i0.ɵɵFactoryDeclaration<WebUsbService, never>;
1023
+ static ɵprov: i0.ɵɵInjectableDeclaration<WebUsbService>;
1024
+ }
1025
+
1026
+ declare class WebNfcService {
1027
+ private readonly platformId;
1028
+ isSupported(): boolean;
1029
+ scan(): Observable<NdefReadingEvent>;
1030
+ write(message: NdefMessage | string, options?: NdefWriteOptions): Promise<void>;
1031
+ static ɵfac: i0.ɵɵFactoryDeclaration<WebNfcService, never>;
1032
+ static ɵprov: i0.ɵɵInjectableDeclaration<WebNfcService>;
1033
+ }
1034
+
1035
+ interface PaymentMethodConfig {
1036
+ supportedMethods: string;
1037
+ data?: Record<string, unknown>;
1038
+ }
1039
+ interface PaymentDetailsInit {
1040
+ total: {
1041
+ label: string;
1042
+ amount: {
1043
+ currency: string;
1044
+ value: string;
1045
+ };
1046
+ };
1047
+ displayItems?: Array<{
1048
+ label: string;
1049
+ amount: {
1050
+ currency: string;
1051
+ value: string;
1052
+ };
1053
+ }>;
1054
+ }
1055
+ interface PaymentOptionsConfig {
1056
+ requestPayerName?: boolean;
1057
+ requestPayerEmail?: boolean;
1058
+ requestPayerPhone?: boolean;
1059
+ requestShipping?: boolean;
1060
+ }
1061
+ interface PaymentResult {
1062
+ methodName: string;
1063
+ details: Record<string, unknown>;
1064
+ payerName: string | null;
1065
+ payerEmail: string | null;
1066
+ payerPhone: string | null;
1067
+ }
1068
+ declare class PaymentRequestService {
1069
+ private readonly platformId;
1070
+ isSupported(): boolean;
1071
+ canMakePayment(methods: PaymentMethodConfig[], details: PaymentDetailsInit): Promise<boolean>;
1072
+ show(methods: PaymentMethodConfig[], details: PaymentDetailsInit, options?: PaymentOptionsConfig): Promise<PaymentResult>;
1073
+ abort(methods: PaymentMethodConfig[], details: PaymentDetailsInit): Promise<void>;
1074
+ static ɵfac: i0.ɵɵFactoryDeclaration<PaymentRequestService, never>;
1075
+ static ɵprov: i0.ɵɵInjectableDeclaration<PaymentRequestService>;
1076
+ }
1077
+
1078
+ interface PasswordCredentialData {
1079
+ id: string;
1080
+ password: string;
1081
+ name?: string;
1082
+ iconURL?: string;
1083
+ }
1084
+ interface PublicKeyCredentialOptions {
1085
+ challenge: BufferSource;
1086
+ rp: {
1087
+ name: string;
1088
+ id?: string;
1089
+ };
1090
+ user: {
1091
+ id: BufferSource;
1092
+ name: string;
1093
+ displayName: string;
1094
+ };
1095
+ pubKeyCredParams: Array<{
1096
+ type: 'public-key';
1097
+ alg: number;
1098
+ }>;
1099
+ timeout?: number;
1100
+ attestation?: AttestationConveyancePreference;
1101
+ authenticatorSelection?: AuthenticatorSelectionCriteria;
1102
+ }
1103
+ interface CredentialResult {
1104
+ id: string;
1105
+ type: string;
1106
+ }
1107
+ declare class CredentialManagementService {
1108
+ private readonly platformId;
1109
+ isSupported(): boolean;
1110
+ isPublicKeySupported(): boolean;
1111
+ get(options?: CredentialRequestOptions): Promise<Credential | null>;
1112
+ store(credential: Credential): Promise<void>;
1113
+ createPasswordCredential(data: PasswordCredentialData): Promise<Credential>;
1114
+ createPublicKeyCredential(options: PublicKeyCredentialOptions): Promise<Credential | null>;
1115
+ preventSilentAccess(): Promise<void>;
1116
+ isConditionalMediationAvailable(): Promise<boolean>;
1117
+ static ɵfac: i0.ɵɵFactoryDeclaration<CredentialManagementService, never>;
1118
+ static ɵprov: i0.ɵɵInjectableDeclaration<CredentialManagementService>;
1119
+ }
1120
+
714
1121
  interface MediaDevice {
715
1122
  deviceId: string;
716
1123
  groupId: string;
@@ -814,13 +1221,13 @@ interface ResizeRef {
814
1221
  readonly inlineSize: Signal<number>;
815
1222
  readonly blockSize: Signal<number>;
816
1223
  }
817
- declare function injectResizeObserver(elementOrRef: Element | ElementRef<Element>, options?: ResizeObserverOptions): ResizeRef;
1224
+ declare function injectResizeObserver(elementOrRef: ElementInput, options?: ResizeObserverOptions): ResizeRef;
818
1225
 
819
1226
  interface IntersectionRef {
820
1227
  readonly isIntersecting: Signal<boolean>;
821
1228
  readonly isVisible: Signal<boolean>;
822
1229
  }
823
- declare function injectIntersectionObserver(elementOrRef: Element | ElementRef<Element>, options?: IntersectionObserverOptions): IntersectionRef;
1230
+ declare function injectIntersectionObserver(elementOrRef: ElementInput, options?: IntersectionObserverOptions): IntersectionRef;
824
1231
 
825
1232
  interface NetworkInformationRef {
826
1233
  readonly snapshot: Signal<NetworkInformation>;
@@ -844,6 +1251,39 @@ interface ScreenOrientationRef {
844
1251
  }
845
1252
  declare function injectScreenOrientation(): ScreenOrientationRef;
846
1253
 
1254
+ interface MutationRef {
1255
+ readonly mutations: Signal<MutationRecord[]>;
1256
+ readonly mutationCount: Signal<number>;
1257
+ }
1258
+ declare function injectMutationObserver(elementOrRef: ElementInput, options?: MutationObserverOptions): MutationRef;
1259
+
1260
+ interface PerformanceObserverRef {
1261
+ readonly entries: Signal<PerformanceEntryList>;
1262
+ readonly entryCount: Signal<number>;
1263
+ readonly latestEntry: Signal<PerformanceEntry | undefined>;
1264
+ }
1265
+ declare function injectPerformanceObserver(config: PerformanceObserverConfig): PerformanceObserverRef;
1266
+
1267
+ interface IdleDetectorRef {
1268
+ readonly state: Signal<IdleState>;
1269
+ readonly userState: Signal<UserIdleState>;
1270
+ readonly screenState: Signal<ScreenIdleState>;
1271
+ readonly isUserIdle: Signal<boolean>;
1272
+ readonly isScreenLocked: Signal<boolean>;
1273
+ }
1274
+ declare function injectIdleDetector(options?: IdleDetectorOptions): IdleDetectorRef;
1275
+
1276
+ interface GamepadRef {
1277
+ readonly state: Signal<GamepadState | null>;
1278
+ readonly connected: Signal<boolean>;
1279
+ readonly buttons: Signal<ReadonlyArray<{
1280
+ pressed: boolean;
1281
+ value: number;
1282
+ }>>;
1283
+ readonly axes: Signal<readonly number[]>;
1284
+ }
1285
+ declare function injectGamepad(index: number, intervalMs?: number): GamepadRef;
1286
+
847
1287
  declare class BrowserSupportUtil {
848
1288
  static isSupported(feature: string): boolean;
849
1289
  static getUnsupportedFeatures(): string[];
@@ -893,6 +1333,18 @@ interface BrowserWebApisConfig {
893
1333
  enableServerSentEvents?: boolean;
894
1334
  enableVibration?: boolean;
895
1335
  enableSpeechSynthesis?: boolean;
1336
+ enableMutationObserver?: boolean;
1337
+ enablePerformanceObserver?: boolean;
1338
+ enableIdleDetector?: boolean;
1339
+ enableEyeDropper?: boolean;
1340
+ enableBarcodeDetector?: boolean;
1341
+ enableWebAudio?: boolean;
1342
+ enableGamepad?: boolean;
1343
+ enableWebBluetooth?: boolean;
1344
+ enableWebUsb?: boolean;
1345
+ enableWebNfc?: boolean;
1346
+ enablePaymentRequest?: boolean;
1347
+ enableCredentialManagement?: boolean;
896
1348
  }
897
1349
  declare const defaultBrowserWebApisConfig: BrowserWebApisConfig;
898
1350
  declare function provideBrowserWebApis(config?: BrowserWebApisConfig): EnvironmentProviders;
@@ -924,8 +1376,20 @@ declare function provideMediaRecorder(): EnvironmentProviders;
924
1376
  declare function provideServerSentEvents(): EnvironmentProviders;
925
1377
  declare function provideVibration(): EnvironmentProviders;
926
1378
  declare function provideSpeechSynthesis(): EnvironmentProviders;
1379
+ declare function provideMutationObserver(): EnvironmentProviders;
1380
+ declare function providePerformanceObserver(): EnvironmentProviders;
1381
+ declare function provideIdleDetector(): EnvironmentProviders;
1382
+ declare function provideEyeDropper(): EnvironmentProviders;
1383
+ declare function provideBarcodeDetector(): EnvironmentProviders;
1384
+ declare function provideWebAudio(): EnvironmentProviders;
1385
+ declare function provideGamepad(): EnvironmentProviders;
1386
+ declare function provideWebBluetooth(): EnvironmentProviders;
1387
+ declare function provideWebUsb(): EnvironmentProviders;
1388
+ declare function provideWebNfc(): EnvironmentProviders;
1389
+ declare function providePaymentRequest(): EnvironmentProviders;
1390
+ declare function provideCredentialManagement(): EnvironmentProviders;
927
1391
 
928
1392
  declare const version = "0.1.0";
929
1393
 
930
- export { BatteryService, BroadcastChannelService, BrowserApiBaseService, BrowserCapabilityService, BrowserSupportUtil, CameraService, ClipboardService, FileSystemAccessService, FullscreenService, GeolocationService, IntersectionObserverService, MediaDevicesService, MediaRecorderService, NetworkInformationService, NotificationService, PageVisibilityService, PermissionsService, ResizeObserverService, ScreenOrientationService, ScreenWakeLockService, ServerSentEventsService, SpeechSynthesisService, VibrationService, WebShareService, WebSocketService, WebStorageService, WebWorkerService, permissionGuard as createPermissionGuard, defaultBrowserWebApisConfig, injectIntersectionObserver, injectNetworkInformation, injectPageVisibility, injectResizeObserver, injectScreenOrientation, permissionGuard, provideBattery, provideBroadcastChannel, provideBrowserWebApis, provideCamera, provideClipboard, provideCommunicationApis, provideFileSystemAccess, provideFullscreen, provideGeolocation, provideIntersectionObserver, provideLocationApis, provideMediaApis, provideMediaDevices, provideMediaRecorder, provideNetworkInformation, provideNotifications, providePageVisibility, providePermissions, provideResizeObserver, provideScreenOrientation, provideScreenWakeLock, provideServerSentEvents, provideSpeechSynthesis, provideStorageApis, provideVibration, provideWebShare, provideWebSocket, provideWebStorage, provideWebWorker, version };
931
- export type { BatteryInfo, BatteryManager, BrowserCapabilityId, BrowserError, BrowserPermissions, BrowserWebApisConfig, CameraCapabilities, CameraInfo, ConnectionType, EffectiveConnectionType, ElementSize, ErrorCallback, EventHandler, FileOpenOptions, FileSaveOptions, GeolocationCoordinates, GeolocationError, GeolocationOptions, GeolocationPosition$1 as GeolocationPosition, GeolocationWatchOptions, IntersectionObserverOptions, IntersectionRef, MediaDevice, MediaDeviceKind, MediaDevicesInfo, MediaStreamConstraints$1 as MediaStreamConstraints, MediaTrackConstraints$1 as MediaTrackConstraints, NetworkInformation, NetworkInformationRef, OrientationInfo, OrientationLockType, OrientationType, PageVisibilityRef, PermissionNameExt, PermissionRequest, RecordingOptions, RecordingResult, RecordingState, ResizeObserverOptions, ResizeRef, SSEConfig, SSEConnectionState, SSEMessage, ScreenOrientationRef, SpeechOptions, SpeechState, StorageEvent, StorageOptions, StorageValue, VibrationPattern, VibrationPreset, VisibilityState, WakeLockStatus, WakeLockType, WebSocketConfig, WebSocketMessage, WebSocketStatus, WorkerMessage, WorkerStatus, WorkerTask };
1394
+ export { BarcodeDetectorService, BatteryService, BroadcastChannelService, BrowserApiBaseService, BrowserCapabilityService, BrowserSupportUtil, CameraService, ClipboardService, CredentialManagementService, EyeDropperService, FileSystemAccessService, FullscreenService, GamepadService, GeolocationService, IdleDetectorService, IntersectionObserverService, MediaDevicesService, MediaRecorderService, MutationObserverService, NetworkInformationService, NotificationService, PageVisibilityService, PaymentRequestService, PerformanceObserverService, PermissionsService, ResizeObserverService, ScreenOrientationService, ScreenWakeLockService, ServerSentEventsService, SpeechSynthesisService, VibrationService, WebAudioService, WebBluetoothService, WebNfcService, WebShareService, WebSocketService, WebStorageService, WebUsbService, WebWorkerService, permissionGuard as createPermissionGuard, defaultBrowserWebApisConfig, injectGamepad, injectIdleDetector, injectIntersectionObserver, injectMutationObserver, injectNetworkInformation, injectPageVisibility, injectPerformanceObserver, injectResizeObserver, injectScreenOrientation, permissionGuard, provideBarcodeDetector, provideBattery, provideBroadcastChannel, provideBrowserWebApis, provideCamera, provideClipboard, provideCommunicationApis, provideCredentialManagement, provideEyeDropper, provideFileSystemAccess, provideFullscreen, provideGamepad, provideGeolocation, provideIdleDetector, provideIntersectionObserver, provideLocationApis, provideMediaApis, provideMediaDevices, provideMediaRecorder, provideMutationObserver, provideNetworkInformation, provideNotifications, providePageVisibility, providePaymentRequest, providePerformanceObserver, providePermissions, provideResizeObserver, provideScreenOrientation, provideScreenWakeLock, provideServerSentEvents, provideSpeechSynthesis, provideStorageApis, provideVibration, provideWebAudio, provideWebBluetooth, provideWebNfc, provideWebShare, provideWebSocket, provideWebStorage, provideWebUsb, provideWebWorker, version };
1395
+ export type { AudioAnalyserData, AudioContextState, BarcodeFormat, BatteryInfo, BatteryManager, BluetoothDeviceInfo, BluetoothDeviceRef, BluetoothRequestDeviceOptions, BrowserCapabilityId, BrowserError, BrowserPermissions, BrowserWebApisConfig, CameraCapabilities, CameraInfo, ColorSelectionResult, ConnectionType, CredentialResult, DetectedBarcode, EffectiveConnectionType, ElementInput, ElementSize, ErrorCallback, EventHandler, FileOpenOptions, FileSaveOptions, GamepadRef, GamepadState, GeolocationCoordinates, GeolocationError, GeolocationOptions, GeolocationPosition$1 as GeolocationPosition, GeolocationWatchOptions, IdleDetectorOptions, IdleDetectorRef, IdleState, IntersectionObserverOptions, IntersectionRef, MediaDevice, MediaDeviceKind, MediaDevicesInfo, MediaStreamConstraints$1 as MediaStreamConstraints, MediaTrackConstraints$1 as MediaTrackConstraints, MutationObserverOptions, MutationRef, NdefMessage, NdefReadingEvent, NdefWriteOptions, NetworkInformation, NetworkInformationRef, OrientationInfo, OrientationLockType, OrientationType, PageVisibilityRef, PasswordCredentialData, PaymentDetailsInit, PaymentMethodConfig, PaymentOptionsConfig, PaymentResult, PerformanceEntryType, PerformanceObserverConfig, PerformanceObserverRef, PermissionNameExt, PermissionRequest, PublicKeyCredentialOptions, RecordingOptions, RecordingResult, RecordingState, ResizeObserverOptions, ResizeRef, SSEConfig, SSEConnectionState, SSEMessage, ScreenIdleState, ScreenOrientationRef, SpeechOptions, SpeechState, StorageEvent, StorageOptions, StorageValue, UsbDeviceFilterDef, UsbDeviceInfo, UsbDeviceRef, UserIdleState, VibrationPattern, VibrationPreset, VisibilityState, WakeLockStatus, WakeLockType, WebSocketConfig, WebSocketMessage, WebSocketStatus, WorkerMessage, WorkerStatus, WorkerTask };