This commit is contained in:
2026-10-22 16:06:51 +07:00
commit 25158e780f
2897 changed files with 569062 additions and 0 deletions
+8
View File
@@ -0,0 +1,8 @@
export declare class BitStream {
private bytes;
private byteOffset;
private bitOffset;
constructor(bytes: Uint8ClampedArray);
readBits(numBits: number): number;
available(): number;
}
+27
View File
@@ -0,0 +1,27 @@
export interface Chunk {
type: Mode;
text: string;
}
export interface ByteChunk {
type: Mode.Byte | Mode.Kanji;
bytes: number[];
}
export interface ECIChunk {
type: Mode.ECI;
assignmentNumber: number;
}
export declare type Chunks = Array<Chunk | ByteChunk | ECIChunk>;
export interface DecodedQR {
text: string;
bytes: number[];
chunks: Chunks;
version: number;
}
export declare enum Mode {
Numeric = "numeric",
Alphanumeric = "alphanumeric",
Byte = "byte",
Kanji = "kanji",
ECI = "eci"
}
export declare function decode(data: Uint8ClampedArray, version: number): DecodedQR;
+3
View File
@@ -0,0 +1,3 @@
export declare const shiftJISTable: {
[key: number]: number;
};