@thermal-label/d1-core
Interfaces
| Interface | Description |
|---|---|
| D1Media | D1 tape media descriptor — minimum shape needed by the encoder. |
| D1PrintOptions | Print-time options understood by buildPrinterStream. |
Type Aliases
| Type Alias | Description |
|---|---|
| D1Material | D1 substrate family. Picker / preview UX hint — the rasterizer does not branch on this. The rhino-* values cover DYMO's industrial Rhino™ cartridge line. |
| D1MediaKey | - |
Variables
| Variable | Description |
|---|---|
| D1_MEDIA | - |
| D1_MEDIA_LIST | - |
| D1_TAPE_12MM | Canonical 12 mm Black-on-White cartridge — picker default. |
| D1_TAPE_19MM | Canonical 19 mm Black-on-White cartridge — picker default. |
| D1_TAPE_24MM | Canonical 24 mm Black-on-White cartridge — picker default. |
| D1_TAPE_6MM | Canonical 6 mm Black-on-White cartridge — picker default. |
| D1_TAPE_9MM | Canonical 9 mm Black-on-White cartridge — picker default. |
| STATUS_REQUEST | Status request — ESC A. |
| TAPE_TYPE_DEFAULT | ESC C n — D1 tape-type / colour-palette selector. |
| TAPE_TYPE_MAX | - |
Functions
| Function | Description |
|---|---|
| buildPrinterStream | Build a raw byte stream for the USB Printer-class endpoint. |
| findAllD1MediaByTapeWidth | Find every catalogued cartridge for a given tape width. |
| findD1MediaById | Look up an entry by its kebab-case id. Convenience for callers that have an id in hand and want the full descriptor without iterating the keyed registry. |
| findD1MediaByTapeWidth | Find the canonical Black-on-White cartridge for a given tape width. |
| parseStatus | Parse a D1 status reply (8 bytes; only byte 0 used). |
| tapeTypeFor | Map the user-selected media's text + background colours to the ESC C selector (0..12). Unknown / unenumerated combinations and undefined media both return 0, the safe fallback (the cassette's ink prints regardless of the byte sent). |