@psdk/esc 0.2.67 → 0.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (48) hide show
  1. package/build/args/backlinedot.js +4 -8
  2. package/build/args/basic.js +2 -6
  3. package/build/args/batteryvolume.js +2 -6
  4. package/build/args/bttype.js +2 -6
  5. package/build/args/enable.js +2 -6
  6. package/build/args/getpapertypeq3.d.ts +5 -0
  7. package/build/args/getpapertypeq3.d.ts.map +1 -0
  8. package/build/args/getpapertypeq3.js +6 -0
  9. package/build/args/getshutdowntime.js +2 -6
  10. package/build/args/image.js +9 -13
  11. package/build/args/index.js +25 -41
  12. package/build/args/info.js +2 -6
  13. package/build/args/learnlabelgap.js +2 -6
  14. package/build/args/line.js +4 -8
  15. package/build/args/linedot.js +4 -8
  16. package/build/args/location.js +4 -8
  17. package/build/args/mac.js +2 -6
  18. package/build/args/model.js +2 -6
  19. package/build/args/name.js +2 -6
  20. package/build/args/papertype.js +6 -10
  21. package/build/args/papertypeq3.d.ts +12 -0
  22. package/build/args/papertypeq3.d.ts.map +1 -0
  23. package/build/args/papertypeq3.js +17 -0
  24. package/build/args/position.js +2 -6
  25. package/build/args/printerversion.js +2 -6
  26. package/build/args/setshutdowntime.js +4 -8
  27. package/build/args/sn.js +2 -6
  28. package/build/args/state.js +2 -6
  29. package/build/args/stopjob.js +2 -6
  30. package/build/args/thickness.js +4 -8
  31. package/build/args/version.js +2 -6
  32. package/build/args/wakeup.js +2 -6
  33. package/build/impls/basic.d.ts +11 -1
  34. package/build/impls/basic.d.ts.map +1 -1
  35. package/build/impls/basic.js +40 -31
  36. package/build/impls/esc.js +3 -7
  37. package/build/impls/generic.js +2 -6
  38. package/build/impls/index.js +2 -18
  39. package/build/index.js +2 -18
  40. package/build/types/image.js +2 -5
  41. package/build/types/index.d.ts +1 -0
  42. package/build/types/index.d.ts.map +1 -1
  43. package/build/types/index.js +3 -18
  44. package/build/types/papertype.js +2 -5
  45. package/build/types/papertypeq3.d.ts +15 -0
  46. package/build/types/papertypeq3.d.ts.map +1 -0
  47. package/build/types/papertypeq3.js +15 -0
  48. package/package.json +14 -33
@@ -1,23 +1,19 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.EBackLineDot = void 0;
4
- const basic_1 = require("./basic");
5
- const frame_father_1 = require("@psdk/frame-father");
1
+ import { BasicESCArg } from "./basic";
2
+ import { BinaryCommand } from "@psdk/frame-father";
6
3
  /**
7
4
  * BackLineDot
8
5
  */
9
- class EBackLineDot extends basic_1.BasicESCArg {
6
+ export class EBackLineDot extends BasicESCArg {
10
7
  constructor(options) {
11
8
  var _a;
12
9
  super();
13
10
  this.dot = (_a = options.dot) !== null && _a !== void 0 ? _a : 0;
14
11
  }
15
12
  clause() {
16
- return frame_father_1.BinaryCommand.with(this.header())
13
+ return BinaryCommand.with(this.header())
17
14
  .appendNumber(this.dot).clause();
18
15
  }
19
16
  header() {
20
17
  return new Uint8Array([0x10, 0xFF, 0x81]);
21
18
  }
22
19
  }
23
- exports.EBackLineDot = EBackLineDot;
@@ -1,8 +1,5 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.BasicESCArg = void 0;
4
- const frame_father_1 = require("@psdk/frame-father");
5
- class BasicESCArg extends frame_father_1.EasyArg {
1
+ import { EasyArg } from "@psdk/frame-father";
2
+ export class BasicESCArg extends EasyArg {
6
3
  append(arg) {
7
4
  super.append(arg);
8
5
  return this;
@@ -15,4 +12,3 @@ class BasicESCArg extends frame_father_1.EasyArg {
15
12
  return false;
16
13
  }
17
14
  }
18
- exports.BasicESCArg = BasicESCArg;
@@ -1,10 +1,6 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.EBatteryVolume = void 0;
4
- const frame_father_1 = require("@psdk/frame-father");
5
- class EBatteryVolume extends frame_father_1.OnlyBinaryHeaderArg {
1
+ import { OnlyBinaryHeaderArg } from "@psdk/frame-father";
2
+ export class EBatteryVolume extends OnlyBinaryHeaderArg {
6
3
  header() {
7
4
  return new Uint8Array([0x10, 0xFF, 0x50, 0xF1]);
8
5
  }
9
6
  }
10
- exports.EBatteryVolume = EBatteryVolume;
@@ -1,10 +1,6 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.EBTType = void 0;
4
- const frame_father_1 = require("@psdk/frame-father");
5
- class EBTType extends frame_father_1.OnlyBinaryHeaderArg {
1
+ import { OnlyBinaryHeaderArg } from "@psdk/frame-father";
2
+ export class EBTType extends OnlyBinaryHeaderArg {
6
3
  header() {
7
4
  return new Uint8Array([0x1F, 0xB2, 0x10]);
8
5
  }
9
6
  }
10
- exports.EBTType = EBTType;
@@ -1,10 +1,6 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.EEnable = void 0;
4
- const frame_father_1 = require("@psdk/frame-father");
5
- class EEnable extends frame_father_1.OnlyBinaryHeaderArg {
1
+ import { OnlyBinaryHeaderArg } from "@psdk/frame-father";
2
+ export class EEnable extends OnlyBinaryHeaderArg {
6
3
  header() {
7
4
  return new Uint8Array([0x10, 0xFF, 0xFE, 0x01]);
8
5
  }
9
6
  }
10
- exports.EEnable = EEnable;
@@ -0,0 +1,5 @@
1
+ import { OnlyBinaryHeaderArg } from "@psdk/frame-father";
2
+ export declare class EGetPaperTypeQ3 extends OnlyBinaryHeaderArg<EGetPaperTypeQ3> {
3
+ header(): Uint8Array;
4
+ }
5
+ //# sourceMappingURL=getpapertypeq3.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"getpapertypeq3.d.ts","sourceRoot":"","sources":["../../src/args/getpapertypeq3.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,mBAAmB,EAAC,MAAM,oBAAoB,CAAC;AAEvD,qBAAa,eAAgB,SAAQ,mBAAmB,CAAC,eAAe,CAAC;IAEvE,MAAM,IAAI,UAAU;CAGrB"}
@@ -0,0 +1,6 @@
1
+ import { OnlyBinaryHeaderArg } from "@psdk/frame-father";
2
+ export class EGetPaperTypeQ3 extends OnlyBinaryHeaderArg {
3
+ header() {
4
+ return new Uint8Array([0x10, 0xFF, 0x85]);
5
+ }
6
+ }
@@ -1,10 +1,6 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.EGetShutdownTime = void 0;
4
- const frame_father_1 = require("@psdk/frame-father");
5
- class EGetShutdownTime extends frame_father_1.OnlyBinaryHeaderArg {
1
+ import { OnlyBinaryHeaderArg } from "@psdk/frame-father";
2
+ export class EGetShutdownTime extends OnlyBinaryHeaderArg {
6
3
  header() {
7
4
  return new Uint8Array([0x10, 0xFF, 0x13]);
8
5
  }
9
6
  }
10
- exports.EGetShutdownTime = EGetShutdownTime;
@@ -1,25 +1,22 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.EImage = void 0;
4
- const basic_1 = require("./basic");
5
- const frame_father_1 = require("@psdk/frame-father");
6
- const types_1 = require("../types");
7
- const frame_imageb_1 = require("@psdk/frame-imageb");
1
+ import { BasicESCArg } from "./basic";
2
+ import { BinaryCommand } from "@psdk/frame-father";
3
+ import { EImageMode } from "../types";
4
+ import { Pbita } from "@psdk/frame-imageb";
8
5
  /**
9
6
  * Image
10
7
  */
11
- class EImage extends basic_1.BasicESCArg {
8
+ export class EImage extends BasicESCArg {
12
9
  constructor(options) {
13
10
  var _a, _b, _c, _d;
14
11
  super();
15
12
  this.compress = (_a = options.compress) !== null && _a !== void 0 ? _a : false;
16
13
  this.reverse = (_b = options.reverse) !== null && _b !== void 0 ? _b : false;
17
14
  this.threshold = (_c = options.threshold) !== null && _c !== void 0 ? _c : 190;
18
- this.mode = (_d = options.mode) !== null && _d !== void 0 ? _d : types_1.EImageMode.NORMAL;
15
+ this.mode = (_d = options.mode) !== null && _d !== void 0 ? _d : EImageMode.NORMAL;
19
16
  this.image = options.image;
20
17
  }
21
18
  clause() {
22
- const processer = new frame_imageb_1.Pbita({
19
+ const processer = new Pbita({
23
20
  command: 'esc',
24
21
  threshold: this.threshold,
25
22
  compress: this.compress,
@@ -35,7 +32,7 @@ class EImage extends basic_1.BasicESCArg {
35
32
  let height = fimage.height;
36
33
  const eWidth = Math.floor((width % 8 === 0) ? (width / 8) : (width / 8 + 1));
37
34
  if (this.compress) {
38
- return frame_father_1.BinaryCommand.with(this.header())
35
+ return BinaryCommand.with(this.header())
39
36
  .appendNumber(eWidth / 256)
40
37
  .appendNumber(eWidth % 256)
41
38
  .appendNumber(height / 256)
@@ -47,7 +44,7 @@ class EImage extends basic_1.BasicESCArg {
47
44
  .appendU8A(fbytes.subarray(2, fbytes.length))
48
45
  .clause();
49
46
  }
50
- return frame_father_1.BinaryCommand.with(this.header())
47
+ return BinaryCommand.with(this.header())
51
48
  .appendNumber(this.mode)
52
49
  .appendNumber(eWidth % 256)
53
50
  .appendNumber(eWidth / 256)
@@ -60,4 +57,3 @@ class EImage extends basic_1.BasicESCArg {
60
57
  return new Uint8Array(this.compress ? [0x1F, 0x00] : [0x1D, 0x76, 0x30]);
61
58
  }
62
59
  }
63
- exports.EImage = EImage;
@@ -1,41 +1,25 @@
1
- "use strict";
2
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
- if (k2 === undefined) k2 = k;
4
- var desc = Object.getOwnPropertyDescriptor(m, k);
5
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
- desc = { enumerable: true, get: function() { return m[k]; } };
7
- }
8
- Object.defineProperty(o, k2, desc);
9
- }) : (function(o, m, k, k2) {
10
- if (k2 === undefined) k2 = k;
11
- o[k2] = m[k];
12
- }));
13
- var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
- for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
- };
16
- Object.defineProperty(exports, "__esModule", { value: true });
17
- __exportStar(require("./backlinedot"), exports);
18
- __exportStar(require("./basic"), exports);
19
- __exportStar(require("./batteryvolume"), exports);
20
- __exportStar(require("./enable"), exports);
21
- __exportStar(require("./getshutdowntime"), exports);
22
- __exportStar(require("./image"), exports);
23
- __exportStar(require("./learnlabelgap"), exports);
24
- __exportStar(require("./line"), exports);
25
- __exportStar(require("./linedot"), exports);
26
- __exportStar(require("./location"), exports);
27
- __exportStar(require("./mac"), exports);
28
- __exportStar(require("./model"), exports);
29
- __exportStar(require("./name"), exports);
30
- __exportStar(require("./papertype"), exports);
31
- __exportStar(require("./position"), exports);
32
- __exportStar(require("./printerversion"), exports);
33
- __exportStar(require("./setshutdowntime"), exports);
34
- __exportStar(require("./sn"), exports);
35
- __exportStar(require("./state"), exports);
36
- __exportStar(require("./stopjob"), exports);
37
- __exportStar(require("./thickness"), exports);
38
- __exportStar(require("./version"), exports);
39
- __exportStar(require("./wakeup"), exports);
40
- __exportStar(require("./info"), exports);
41
- __exportStar(require("./bttype"), exports);
1
+ export * from './backlinedot';
2
+ export * from './basic';
3
+ export * from './batteryvolume';
4
+ export * from './enable';
5
+ export * from './getshutdowntime';
6
+ export * from './image';
7
+ export * from './learnlabelgap';
8
+ export * from './line';
9
+ export * from './linedot';
10
+ export * from './location';
11
+ export * from './mac';
12
+ export * from './model';
13
+ export * from './name';
14
+ export * from './papertype';
15
+ export * from './position';
16
+ export * from './printerversion';
17
+ export * from './setshutdowntime';
18
+ export * from './sn';
19
+ export * from './state';
20
+ export * from './stopjob';
21
+ export * from './thickness';
22
+ export * from './version';
23
+ export * from './wakeup';
24
+ export * from './info';
25
+ export * from './bttype';
@@ -1,10 +1,6 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.EInfo = void 0;
4
- const frame_father_1 = require("@psdk/frame-father");
5
- class EInfo extends frame_father_1.OnlyBinaryHeaderArg {
1
+ import { OnlyBinaryHeaderArg } from "@psdk/frame-father";
2
+ export class EInfo extends OnlyBinaryHeaderArg {
6
3
  header() {
7
4
  return new Uint8Array([0x10, 0xFF, 0x70]);
8
5
  }
9
6
  }
10
- exports.EInfo = EInfo;
@@ -1,10 +1,6 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.ELearnLabelGap = void 0;
4
- const frame_father_1 = require("@psdk/frame-father");
5
- class ELearnLabelGap extends frame_father_1.OnlyBinaryHeaderArg {
1
+ import { OnlyBinaryHeaderArg } from "@psdk/frame-father";
2
+ export class ELearnLabelGap extends OnlyBinaryHeaderArg {
6
3
  header() {
7
4
  return new Uint8Array([0x10, 0xFF, 0x03]);
8
5
  }
9
6
  }
10
- exports.ELearnLabelGap = ELearnLabelGap;
@@ -1,12 +1,9 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.ELine = void 0;
4
- const basic_1 = require("./basic");
5
- const frame_father_1 = require("@psdk/frame-father");
1
+ import { BasicESCArg } from "./basic";
2
+ import { BinaryCommand } from "@psdk/frame-father";
6
3
  /**
7
4
  * Line
8
5
  */
9
- class ELine extends basic_1.BasicESCArg {
6
+ export class ELine extends BasicESCArg {
10
7
  constructor(options) {
11
8
  var _a, _b;
12
9
  super();
@@ -14,7 +11,7 @@ class ELine extends basic_1.BasicESCArg {
14
11
  this.y = (_b = options.y) !== null && _b !== void 0 ? _b : 0;
15
12
  }
16
13
  clause() {
17
- return frame_father_1.BinaryCommand.with(this.header())
14
+ return BinaryCommand.with(this.header())
18
15
  .appendNumber(this.x)
19
16
  .appendNumber(this.y)
20
17
  .clause();
@@ -23,4 +20,3 @@ class ELine extends basic_1.BasicESCArg {
23
20
  return new Uint8Array([0x00, 0x01]);
24
21
  }
25
22
  }
26
- exports.ELine = ELine;
@@ -1,23 +1,19 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.ELineDot = void 0;
4
- const basic_1 = require("./basic");
5
- const frame_father_1 = require("@psdk/frame-father");
1
+ import { BasicESCArg } from "./basic";
2
+ import { BinaryCommand } from "@psdk/frame-father";
6
3
  /**
7
4
  * LineDot
8
5
  */
9
- class ELineDot extends basic_1.BasicESCArg {
6
+ export class ELineDot extends BasicESCArg {
10
7
  constructor(options) {
11
8
  var _a;
12
9
  super();
13
10
  this.dot = (_a = options.dot) !== null && _a !== void 0 ? _a : 0;
14
11
  }
15
12
  clause() {
16
- return frame_father_1.BinaryCommand.with(this.header())
13
+ return BinaryCommand.with(this.header())
17
14
  .appendNumber(this.dot).clause();
18
15
  }
19
16
  header() {
20
17
  return new Uint8Array([0x1B, 0x4A]);
21
18
  }
22
19
  }
23
- exports.ELineDot = ELineDot;
@@ -1,23 +1,19 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.ELocation = void 0;
4
- const basic_1 = require("./basic");
5
- const frame_father_1 = require("@psdk/frame-father");
1
+ import { BasicESCArg } from "./basic";
2
+ import { BinaryCommand } from "@psdk/frame-father";
6
3
  /**
7
4
  * Location
8
5
  */
9
- class ELocation extends basic_1.BasicESCArg {
6
+ export class ELocation extends BasicESCArg {
10
7
  constructor(options) {
11
8
  var _a;
12
9
  super();
13
10
  this.location = (_a = options.location) !== null && _a !== void 0 ? _a : 0;
14
11
  }
15
12
  clause() {
16
- return frame_father_1.BinaryCommand.with(this.header())
13
+ return BinaryCommand.with(this.header())
17
14
  .appendNumber(this.location).clause();
18
15
  }
19
16
  header() {
20
17
  return new Uint8Array([0x1b, 0x61]);
21
18
  }
22
19
  }
23
- exports.ELocation = ELocation;
package/build/args/mac.js CHANGED
@@ -1,10 +1,6 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.EMac = void 0;
4
- const frame_father_1 = require("@psdk/frame-father");
5
- class EMac extends frame_father_1.OnlyBinaryHeaderArg {
1
+ import { OnlyBinaryHeaderArg } from "@psdk/frame-father";
2
+ export class EMac extends OnlyBinaryHeaderArg {
6
3
  header() {
7
4
  return new Uint8Array([0x10, 0xFF, 0x30, 0x12]);
8
5
  }
9
6
  }
10
- exports.EMac = EMac;
@@ -1,10 +1,6 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.EModel = void 0;
4
- const frame_father_1 = require("@psdk/frame-father");
5
- class EModel extends frame_father_1.OnlyBinaryHeaderArg {
1
+ import { OnlyBinaryHeaderArg } from "@psdk/frame-father";
2
+ export class EModel extends OnlyBinaryHeaderArg {
6
3
  header() {
7
4
  return new Uint8Array([0x10, 0xFF, 0x20, 0xF0]);
8
5
  }
9
6
  }
10
- exports.EModel = EModel;
@@ -1,10 +1,6 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.EName = void 0;
4
- const frame_father_1 = require("@psdk/frame-father");
5
- class EName extends frame_father_1.OnlyBinaryHeaderArg {
1
+ import { OnlyBinaryHeaderArg } from "@psdk/frame-father";
2
+ export class EName extends OnlyBinaryHeaderArg {
6
3
  header() {
7
4
  return new Uint8Array([0x10, 0xFF, 0x30, 0x11]);
8
5
  }
9
6
  }
10
- exports.EName = EName;
@@ -1,21 +1,17 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.EPaperType = void 0;
4
- const basic_1 = require("./basic");
5
- const frame_father_1 = require("@psdk/frame-father");
6
- const types_1 = require("../types");
7
- class EPaperType extends basic_1.BasicESCArg {
1
+ import { BasicESCArg } from "./basic";
2
+ import { BinaryCommand } from "@psdk/frame-father";
3
+ import { PaperType } from "../types";
4
+ export class EPaperType extends BasicESCArg {
8
5
  constructor(options) {
9
6
  var _a;
10
7
  super();
11
- this.paperType = (_a = options.paperType) !== null && _a !== void 0 ? _a : types_1.PaperType.FOLDED_BLACK_LABEL_PAPER;
8
+ this.paperType = (_a = options.paperType) !== null && _a !== void 0 ? _a : PaperType.FOLDED_BLACK_LABEL_PAPER;
12
9
  }
13
10
  clause() {
14
- return frame_father_1.BinaryCommand.with(this.header())
11
+ return BinaryCommand.with(this.header())
15
12
  .appendNumber(this.paperType).clause();
16
13
  }
17
14
  header() {
18
15
  return new Uint8Array([0x10, 0xff, 0x10, 0x03]);
19
16
  }
20
17
  }
21
- exports.EPaperType = EPaperType;
@@ -0,0 +1,12 @@
1
+ import { BasicESCArg } from "./basic";
2
+ import { CommandClause } from "@psdk/frame-father";
3
+ import { PaperTypeQ3 } from "../types";
4
+ export declare class EPaperTypeQ3 extends BasicESCArg<EPaperTypeQ3> {
5
+ private readonly paperType;
6
+ constructor(options: {
7
+ paperType?: PaperTypeQ3;
8
+ });
9
+ clause(): CommandClause;
10
+ header(): Uint8Array;
11
+ }
12
+ //# sourceMappingURL=papertypeq3.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"papertypeq3.d.ts","sourceRoot":"","sources":["../../src/args/papertypeq3.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,WAAW,EAAC,MAAM,SAAS,CAAC;AACpC,OAAO,EAAC,aAAa,EAAgB,MAAM,oBAAoB,CAAC;AAChE,OAAO,EAAC,WAAW,EAAC,MAAM,UAAU,CAAC;AAIrC,qBAAa,YAAa,SAAQ,WAAW,CAAC,YAAY,CAAC;IACzD,OAAO,CAAC,QAAQ,CAAC,SAAS,CAAc;gBAE5B,OAAO,EAAE;QACnB,SAAS,CAAC,EAAE,WAAW,CAAC;KACzB;IAKD,MAAM,IAAI,aAAa;IAKvB,MAAM,IAAI,UAAU;CAIrB"}
@@ -0,0 +1,17 @@
1
+ import { BasicESCArg } from "./basic";
2
+ import { BinaryCommand } from "@psdk/frame-father";
3
+ import { PaperTypeQ3 } from "../types";
4
+ export class EPaperTypeQ3 extends BasicESCArg {
5
+ constructor(options) {
6
+ var _a;
7
+ super();
8
+ this.paperType = (_a = options.paperType) !== null && _a !== void 0 ? _a : PaperTypeQ3.CONTINUOUS_REEL_PAPER;
9
+ }
10
+ clause() {
11
+ return BinaryCommand.with(this.header())
12
+ .appendNumber(this.paperType).clause();
13
+ }
14
+ header() {
15
+ return new Uint8Array([0x10, 0xff, 0x84]);
16
+ }
17
+ }
@@ -1,10 +1,6 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.EPosition = void 0;
4
- const frame_father_1 = require("@psdk/frame-father");
5
- class EPosition extends frame_father_1.OnlyBinaryHeaderArg {
1
+ import { OnlyBinaryHeaderArg } from "@psdk/frame-father";
2
+ export class EPosition extends OnlyBinaryHeaderArg {
6
3
  header() {
7
4
  return new Uint8Array([0x1d, 0x0c]);
8
5
  }
9
6
  }
10
- exports.EPosition = EPosition;
@@ -1,10 +1,6 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.EPrinterVersion = void 0;
4
- const frame_father_1 = require("@psdk/frame-father");
5
- class EPrinterVersion extends frame_father_1.OnlyBinaryHeaderArg {
1
+ import { OnlyBinaryHeaderArg } from "@psdk/frame-father";
2
+ export class EPrinterVersion extends OnlyBinaryHeaderArg {
6
3
  header() {
7
4
  return new Uint8Array([0x10, 0xFF, 0x20, 0xF1]);
8
5
  }
9
6
  }
10
- exports.EPrinterVersion = EPrinterVersion;
@@ -1,16 +1,13 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.ESetShutdownTime = void 0;
4
- const basic_1 = require("./basic");
5
- const frame_father_1 = require("@psdk/frame-father");
6
- class ESetShutdownTime extends basic_1.BasicESCArg {
1
+ import { BasicESCArg } from "./basic";
2
+ import { BinaryCommand } from "@psdk/frame-father";
3
+ export class ESetShutdownTime extends BasicESCArg {
7
4
  constructor(options) {
8
5
  var _a;
9
6
  super();
10
7
  this.time = (_a = options.time) !== null && _a !== void 0 ? _a : 0;
11
8
  }
12
9
  clause() {
13
- return frame_father_1.BinaryCommand.with(this.header())
10
+ return BinaryCommand.with(this.header())
14
11
  .appendNumber(this.time / 256)
15
12
  .appendNumber(this.time % 256)
16
13
  .clause();
@@ -19,4 +16,3 @@ class ESetShutdownTime extends basic_1.BasicESCArg {
19
16
  return new Uint8Array([0x10, 0xFF, 0x12]);
20
17
  }
21
18
  }
22
- exports.ESetShutdownTime = ESetShutdownTime;
package/build/args/sn.js CHANGED
@@ -1,10 +1,6 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.ESN = void 0;
4
- const frame_father_1 = require("@psdk/frame-father");
5
- class ESN extends frame_father_1.OnlyBinaryHeaderArg {
1
+ import { OnlyBinaryHeaderArg } from "@psdk/frame-father";
2
+ export class ESN extends OnlyBinaryHeaderArg {
6
3
  header() {
7
4
  return new Uint8Array([0x10, 0xFF, 0x20, 0xF2]);
8
5
  }
9
6
  }
10
- exports.ESN = ESN;
@@ -1,10 +1,6 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.EState = void 0;
4
- const frame_father_1 = require("@psdk/frame-father");
5
- class EState extends frame_father_1.OnlyBinaryHeaderArg {
1
+ import { OnlyBinaryHeaderArg } from "@psdk/frame-father";
2
+ export class EState extends OnlyBinaryHeaderArg {
6
3
  header() {
7
4
  return new Uint8Array([0x10, 0xFF, 0x40]);
8
5
  }
9
6
  }
10
- exports.EState = EState;
@@ -1,10 +1,6 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.EStopJob = void 0;
4
- const frame_father_1 = require("@psdk/frame-father");
5
- class EStopJob extends frame_father_1.OnlyBinaryHeaderArg {
1
+ import { OnlyBinaryHeaderArg } from "@psdk/frame-father";
2
+ export class EStopJob extends OnlyBinaryHeaderArg {
6
3
  header() {
7
4
  return new Uint8Array([0x10, 0xFF, 0xFE, 0x45]);
8
5
  }
9
6
  }
10
- exports.EStopJob = EStopJob;
@@ -1,20 +1,16 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.EThickness = void 0;
4
- const basic_1 = require("./basic");
5
- const frame_father_1 = require("@psdk/frame-father");
6
- class EThickness extends basic_1.BasicESCArg {
1
+ import { BasicESCArg } from "./basic";
2
+ import { BinaryCommand } from "@psdk/frame-father";
3
+ export class EThickness extends BasicESCArg {
7
4
  constructor(options) {
8
5
  var _a;
9
6
  super();
10
7
  this.thickness = (_a = options.thickness) !== null && _a !== void 0 ? _a : 0;
11
8
  }
12
9
  clause() {
13
- return frame_father_1.BinaryCommand.with(this.header())
10
+ return BinaryCommand.with(this.header())
14
11
  .appendNumber(this.thickness).clause();
15
12
  }
16
13
  header() {
17
14
  return new Uint8Array([0x10, 0xFF, 0x10, 0x00]);
18
15
  }
19
16
  }
20
- exports.EThickness = EThickness;
@@ -1,10 +1,6 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.EVersion = void 0;
4
- const frame_father_1 = require("@psdk/frame-father");
5
- class EVersion extends frame_father_1.OnlyBinaryHeaderArg {
1
+ import { OnlyBinaryHeaderArg } from "@psdk/frame-father";
2
+ export class EVersion extends OnlyBinaryHeaderArg {
6
3
  header() {
7
4
  return new Uint8Array([0x10, 0xFF, 0x30, 0x10]);
8
5
  }
9
6
  }
10
- exports.EVersion = EVersion;
@@ -1,8 +1,5 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.EWakeup = void 0;
4
- const frame_father_1 = require("@psdk/frame-father");
5
- class EWakeup extends frame_father_1.OnlyBinaryHeaderArg {
1
+ import { OnlyBinaryHeaderArg } from "@psdk/frame-father";
2
+ export class EWakeup extends OnlyBinaryHeaderArg {
6
3
  header() {
7
4
  return new Uint8Array([
8
5
  0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
@@ -10,4 +7,3 @@ class EWakeup extends frame_father_1.OnlyBinaryHeaderArg {
10
7
  ]);
11
8
  }
12
9
  }
13
- exports.EWakeup = EWakeup;
@@ -1,5 +1,6 @@
1
1
  import { Commander, ConnectedDevice, Lifecycle, PSDK } from '@psdk/frame-father';
2
2
  import { EImage, ELine, EPaperType } from '../args';
3
+ import { EPaperTypeQ3 } from "../args/papertypeq3";
3
4
  export declare abstract class BasicESC<T extends BasicESC<any>> extends PSDK<T> {
4
5
  /**
5
6
  * lifecycle
@@ -73,7 +74,16 @@ export declare abstract class BasicESC<T extends BasicESC<any>> extends PSDK<T>
73
74
  /**
74
75
  *纸张类型
75
76
  */
76
- paperType(arg?: EPaperType): T;
77
+ paperType(arg: EPaperType): T;
78
+ /**
79
+ * 纸张类型(Q1 Q2 Q3 D11 D30 B21 B22用这个)
80
+ */
81
+ paperTypeQ3(arg: EPaperTypeQ3): T;
82
+ /**
83
+ * 获取当前设备纸张类型(Q1 Q2 Q3 D11 D30 B21 B22用这个)
84
+ * 返回值:0X01 黑标纸,0x02 连续纸,否则:间隙
85
+ */
86
+ getPaperTypeQ3(): T;
77
87
  /**
78
88
  * 打印定位
79
89
  */
@@ -1 +1 @@
1
- {"version":3,"file":"basic.d.ts","sourceRoot":"","sources":["../../src/impls/basic.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,SAAS,EAAE,eAAe,EAAE,SAAS,EAAE,IAAI,EAAC,MAAM,oBAAoB,CAAA;AAC9E,OAAO,EAKL,MAAM,EAEN,KAAK,EAML,UAAU,EAYX,MAAM,SAAS,CAAA;AAGhB,8BAAsB,QAAQ,CAAC,CAAC,SAAS,QAAQ,CAAC,GAAG,CAAC,CAAE,SAAQ,IAAI,CAAC,CAAC,CAAC;IAErE;;;OAGG;IACH,OAAO,CAAC,UAAU,CAAY;IAC9B;;;OAGG;IACH,OAAO,CAAC,UAAU,CAAY;IAE9B,SAAS,aAAa,SAAS,EAAE,SAAS;IAM1C,eAAe,IAAI,eAAe;IAIlC,SAAS,IAAI,SAAS;IAItB;;;OAGG;IAEI,OAAO,CAAC,GAAG,EAAE,MAAM,GAAG,CAAC;IAI9B;;;;OAIG;IACI,WAAW,CAAC,GAAG,EAAE,MAAM,GAAG,CAAC;IAIlC;;OAEG;IACI,aAAa,IAAI,CAAC;IAIzB;;OAEG;IACI,MAAM,IAAI,CAAC;IAIlB;;OAEG;IACI,eAAe,IAAI,CAAC;IAI3B;;OAEG;IACI,KAAK,CAAC,GAAG,EAAE,MAAM,GAAG,CAAC;IAI5B;;OAEG;IACI,aAAa,IAAI,CAAC;IAIzB;;OAEG;IACI,IAAI,CAAC,GAAG,EAAE,KAAK,GAAG,CAAC;IAI1B;;;OAGG;IACI,QAAQ,CAAC,GAAG,EAAE,MAAM,GAAG,CAAC;IAI/B;;OAEG;IACI,GAAG,IAAI,CAAC;IAIf;;OAEG;IACI,IAAI,IAAI,CAAC;IAIhB;;OAEG;IACI,KAAK,IAAI,CAAC;IAIjB;;OAEG;IACI,IAAI,IAAI,CAAC;IAIhB;;OAEG;IACI,SAAS,CAAC,GAAG,CAAC,EAAE,UAAU,GAAG,CAAC;IAIrC;;OAEG;IACI,QAAQ,IAAI,CAAC;IAIpB;;OAEG;IACI,cAAc,IAAI,CAAC;IAI1B;;OAEG;IAEI,eAAe,CAAC,GAAG,EAAE,MAAM;IAIlC;;OAEG;IAEI,EAAE,IAAI,CAAC;IAId;;OAEG;IACI,KAAK,IAAI,CAAC;IAIjB;;OAEG;IAEI,OAAO,IAAI,CAAC;IAInB;;;OAGG;IACI,SAAS,CAAC,GAAG,EAAE,MAAM,GAAG,CAAC;IAIhC;;OAEG;IAEI,OAAO,IAAI,CAAC;IAInB;;OAEG;IAEI,MAAM,IAAI,CAAC;IAIlB;;OAEG;IACI,SAAS,IAAI,CAAC;CAGtB"}
1
+ {"version":3,"file":"basic.d.ts","sourceRoot":"","sources":["../../src/impls/basic.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,SAAS,EAAE,eAAe,EAAE,SAAS,EAAE,IAAI,EAAC,MAAM,oBAAoB,CAAA;AAC9E,OAAO,EAKL,MAAM,EAEN,KAAK,EAML,UAAU,EAYX,MAAM,SAAS,CAAA;AAEhB,OAAO,EAAC,YAAY,EAAC,MAAM,qBAAqB,CAAC;AAGjD,8BAAsB,QAAQ,CAAC,CAAC,SAAS,QAAQ,CAAC,GAAG,CAAC,CAAE,SAAQ,IAAI,CAAC,CAAC,CAAC;IAErE;;;OAGG;IACH,OAAO,CAAC,UAAU,CAAY;IAC9B;;;OAGG;IACH,OAAO,CAAC,UAAU,CAAY;IAE9B,SAAS,aAAa,SAAS,EAAE,SAAS;IAM1C,eAAe,IAAI,eAAe;IAIlC,SAAS,IAAI,SAAS;IAItB;;;OAGG;IAEI,OAAO,CAAC,GAAG,EAAE,MAAM,GAAG,CAAC;IAI9B;;;;OAIG;IACI,WAAW,CAAC,GAAG,EAAE,MAAM,GAAG,CAAC;IAIlC;;OAEG;IACI,aAAa,IAAI,CAAC;IAIzB;;OAEG;IACI,MAAM,IAAI,CAAC;IAIlB;;OAEG;IACI,eAAe,IAAI,CAAC;IAI3B;;OAEG;IACI,KAAK,CAAC,GAAG,EAAE,MAAM,GAAG,CAAC;IAI5B;;OAEG;IACI,aAAa,IAAI,CAAC;IAIzB;;OAEG;IACI,IAAI,CAAC,GAAG,EAAE,KAAK,GAAG,CAAC;IAI1B;;;OAGG;IACI,QAAQ,CAAC,GAAG,EAAE,MAAM,GAAG,CAAC;IAI/B;;OAEG;IACI,GAAG,IAAI,CAAC;IAIf;;OAEG;IACI,IAAI,IAAI,CAAC;IAIhB;;OAEG;IACI,KAAK,IAAI,CAAC;IAIjB;;OAEG;IACI,IAAI,IAAI,CAAC;IAIhB;;OAEG;IACI,SAAS,CAAC,GAAG,EAAE,UAAU,GAAG,CAAC;IAIpC;;OAEG;IACI,WAAW,CAAC,GAAG,EAAE,YAAY,GAAG,CAAC;IAIxC;;;OAGG;IACI,cAAc,IAAI,CAAC;IAI1B;;OAEG;IACI,QAAQ,IAAI,CAAC;IAIpB;;OAEG;IACI,cAAc,IAAI,CAAC;IAI1B;;OAEG;IAEI,eAAe,CAAC,GAAG,EAAE,MAAM;IAIlC;;OAEG;IAEI,EAAE,IAAI,CAAC;IAId;;OAEG;IACI,KAAK,IAAI,CAAC;IAIjB;;OAEG;IAEI,OAAO,IAAI,CAAC;IAInB;;;OAGG;IACI,SAAS,CAAC,GAAG,EAAE,MAAM,GAAG,CAAC;IAIhC;;OAEG;IAEI,OAAO,IAAI,CAAC;IAInB;;OAEG;IAEI,MAAM,IAAI,CAAC;IAIlB;;OAEG;IACI,SAAS,IAAI,CAAC;CAGtB"}
@@ -1,14 +1,11 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.BasicESC = void 0;
4
- const frame_father_1 = require("@psdk/frame-father");
5
- const args_1 = require("../args");
6
- const types_1 = require("../types");
7
- class BasicESC extends frame_father_1.PSDK {
1
+ import { Commander, PSDK } from '@psdk/frame-father';
2
+ import { EBackLineDot, EBatteryVolume, EEnable, EGetShutdownTime, ELearnLabelGap, ELineDot, ELocation, EMac, EModel, EName, EPosition, EPrinterVersion, ESetShutdownTime, ESN, EState, EStopJob, EThickness, EVersion, EWakeup, EBTType, EInfo, } from '../args';
3
+ import { EGetPaperTypeQ3 } from "../args/getpapertypeq3";
4
+ export class BasicESC extends PSDK {
8
5
  constructor(lifecycle) {
9
6
  super();
10
7
  this._lifecycle = lifecycle;
11
- this._commander = frame_father_1.Commander.make();
8
+ this._commander = Commander.make();
12
9
  }
13
10
  connectedDevice() {
14
11
  return this._lifecycle.connectedDevice;
@@ -21,7 +18,7 @@ class BasicESC extends frame_father_1.PSDK {
21
18
  * @param arg
22
19
  */
23
20
  lineDot(arg) {
24
- return super.push(new args_1.ELineDot({ dot: arg }));
21
+ return super.push(new ELineDot({ dot: arg }));
25
22
  }
26
23
  /**
27
24
  * 回纸命令
@@ -29,25 +26,25 @@ class BasicESC extends frame_father_1.PSDK {
29
26
  * @param arg
30
27
  */
31
28
  backLineDot(arg) {
32
- return super.push(new args_1.EBackLineDot({ dot: arg }));
29
+ return super.push(new EBackLineDot({ dot: arg }));
33
30
  }
34
31
  /**
35
32
  * 查询电量
36
33
  */
37
34
  batteryVolume() {
38
- return super.push(new args_1.EBatteryVolume());
35
+ return super.push(new EBatteryVolume());
39
36
  }
40
37
  /**
41
38
  * 使能打印机
42
39
  */
43
40
  enable() {
44
- return super.push(new args_1.EEnable());
41
+ return super.push(new EEnable());
45
42
  }
46
43
  /**
47
44
  * 获取关机时间
48
45
  */
49
46
  getShutdownTime() {
50
- return super.push(new args_1.EGetShutdownTime());
47
+ return super.push(new EGetShutdownTime());
51
48
  }
52
49
  /**
53
50
  * 打印图片
@@ -59,7 +56,7 @@ class BasicESC extends frame_father_1.PSDK {
59
56
  *学习缝隙
60
57
  */
61
58
  learnLabelGap() {
62
- return super.push(new args_1.ELearnLabelGap());
59
+ return super.push(new ELearnLabelGap());
63
60
  }
64
61
  /**
65
62
  *画线
@@ -72,98 +69,110 @@ class BasicESC extends frame_father_1.PSDK {
72
69
  * @param arg 0:居左 1:居中 2:居右
73
70
  */
74
71
  location(arg) {
75
- return super.push(new args_1.ELocation({ location: arg }));
72
+ return super.push(new ELocation({ location: arg }));
76
73
  }
77
74
  /**
78
75
  *查询MAC
79
76
  */
80
77
  mac() {
81
- return super.push(new args_1.EMac());
78
+ return super.push(new EMac());
82
79
  }
83
80
  /**
84
81
  * 查询打印机所有信息
85
82
  */
86
83
  info() {
87
- return super.push(new args_1.EInfo());
84
+ return super.push(new EInfo());
88
85
  }
89
86
  /**
90
87
  *查询打印机型号
91
88
  */
92
89
  model() {
93
- return super.push(new args_1.EModel());
90
+ return super.push(new EModel());
94
91
  }
95
92
  /**
96
93
  *查询蓝牙名称
97
94
  */
98
95
  name() {
99
- return super.push(new args_1.EName());
96
+ return super.push(new EName());
100
97
  }
101
98
  /**
102
99
  *纸张类型
103
100
  */
104
101
  paperType(arg) {
105
- return super.push(arg !== null && arg !== void 0 ? arg : new args_1.EPaperType({ paperType: types_1.PaperType.FOLDED_BLACK_LABEL_PAPER }));
102
+ return super.push(arg);
103
+ }
104
+ /**
105
+ * 纸张类型(Q1 Q2 Q3 D11 D30 B21 B22用这个)
106
+ */
107
+ paperTypeQ3(arg) {
108
+ return super.push(arg);
109
+ }
110
+ /**
111
+ * 获取当前设备纸张类型(Q1 Q2 Q3 D11 D30 B21 B22用这个)
112
+ * 返回值:0X01 黑标纸,0x02 连续纸,否则:间隙
113
+ */
114
+ getPaperTypeQ3() {
115
+ return super.push(new EGetPaperTypeQ3());
106
116
  }
107
117
  /**
108
118
  * 打印定位
109
119
  */
110
120
  position() {
111
- return super.push(new args_1.EPosition());
121
+ return super.push(new EPosition());
112
122
  }
113
123
  /**
114
124
  * 查询打印机固件版本
115
125
  */
116
126
  printerVersion() {
117
- return super.push(new args_1.EPrinterVersion());
127
+ return super.push(new EPrinterVersion());
118
128
  }
119
129
  /**
120
130
  * 设置关机时间
121
131
  */
122
132
  setShutdownTime(arg) {
123
- return super.push(new args_1.ESetShutdownTime({ time: arg }));
133
+ return super.push(new ESetShutdownTime({ time: arg }));
124
134
  }
125
135
  /**
126
136
  *查询SN
127
137
  */
128
138
  sn() {
129
- return super.push(new args_1.ESN());
139
+ return super.push(new ESN());
130
140
  }
131
141
  /**
132
142
  *查询打印机状态
133
143
  */
134
144
  state() {
135
- return super.push(new args_1.EState());
145
+ return super.push(new EState());
136
146
  }
137
147
  /**
138
148
  *结束打印任务
139
149
  */
140
150
  stopJob() {
141
- return super.push(new args_1.EStopJob());
151
+ return super.push(new EStopJob());
142
152
  }
143
153
  /**
144
154
  * 设置打印机浓度(0-2)
145
155
  * @param arg 0:低浓度 1:中浓度 2:高浓度
146
156
  */
147
157
  thickness(arg) {
148
- return super.push(new args_1.EThickness({ thickness: arg }));
158
+ return super.push(new EThickness({ thickness: arg }));
149
159
  }
150
160
  /**
151
161
  *查询蓝牙固件版本
152
162
  */
153
163
  version() {
154
- return super.push(new args_1.EVersion());
164
+ return super.push(new EVersion());
155
165
  }
156
166
  /**
157
167
  *唤醒打印机
158
168
  */
159
169
  wakeup() {
160
- return super.push(new args_1.EWakeup());
170
+ return super.push(new EWakeup());
161
171
  }
162
172
  /**
163
173
  * 设置蓝牙类型(支持压缩的机器需要调用)
164
174
  */
165
175
  setBTType() {
166
- return super.push(new args_1.EBTType());
176
+ return super.push(new EBTType());
167
177
  }
168
178
  }
169
- exports.BasicESC = BasicESC;
@@ -1,17 +1,13 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.ESC = void 0;
4
- const generic_1 = require("./generic");
1
+ import { GenericESC } from "./generic";
5
2
  /**
6
3
  * ESC entrypoint
7
4
  */
8
- class ESC {
5
+ export class ESC {
9
6
  /**
10
7
  * Generic esc command
11
8
  * @param lifecycle lifecycle
12
9
  */
13
10
  static generic(lifecycle) {
14
- return new generic_1.GenericESC(lifecycle);
11
+ return new GenericESC(lifecycle);
15
12
  }
16
13
  }
17
- exports.ESC = ESC;
@@ -1,10 +1,6 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.GenericESC = void 0;
4
- const basic_1 = require("./basic");
5
- class GenericESC extends basic_1.BasicESC {
1
+ import { BasicESC } from "./basic";
2
+ export class GenericESC extends BasicESC {
6
3
  constructor(lifecycle) {
7
4
  super(lifecycle);
8
5
  }
9
6
  }
10
- exports.GenericESC = GenericESC;
@@ -1,18 +1,2 @@
1
- "use strict";
2
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
- if (k2 === undefined) k2 = k;
4
- var desc = Object.getOwnPropertyDescriptor(m, k);
5
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
- desc = { enumerable: true, get: function() { return m[k]; } };
7
- }
8
- Object.defineProperty(o, k2, desc);
9
- }) : (function(o, m, k, k2) {
10
- if (k2 === undefined) k2 = k;
11
- o[k2] = m[k];
12
- }));
13
- var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
- for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
- };
16
- Object.defineProperty(exports, "__esModule", { value: true });
17
- __exportStar(require("./generic"), exports);
18
- __exportStar(require("./esc"), exports);
1
+ export * from './generic';
2
+ export * from './esc';
package/build/index.js CHANGED
@@ -1,18 +1,2 @@
1
- "use strict";
2
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
- if (k2 === undefined) k2 = k;
4
- var desc = Object.getOwnPropertyDescriptor(m, k);
5
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
- desc = { enumerable: true, get: function() { return m[k]; } };
7
- }
8
- Object.defineProperty(o, k2, desc);
9
- }) : (function(o, m, k, k2) {
10
- if (k2 === undefined) k2 = k;
11
- o[k2] = m[k];
12
- }));
13
- var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
- for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
- };
16
- Object.defineProperty(exports, "__esModule", { value: true });
17
- __exportStar(require("./impls"), exports);
18
- __exportStar(require("./args"), exports);
1
+ export * from './impls';
2
+ export * from './args';
@@ -1,10 +1,7 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.EImageMode = void 0;
4
- var EImageMode;
1
+ export var EImageMode;
5
2
  (function (EImageMode) {
6
3
  EImageMode[EImageMode["NORMAL"] = 0] = "NORMAL";
7
4
  EImageMode[EImageMode["DOUBLE_WIDTH"] = 1] = "DOUBLE_WIDTH";
8
5
  EImageMode[EImageMode["DOUBLE_HEIGHT"] = 2] = "DOUBLE_HEIGHT";
9
6
  EImageMode[EImageMode["DOUBLE_WIDTH_HEIGHT"] = 3] = "DOUBLE_WIDTH_HEIGHT";
10
- })(EImageMode = exports.EImageMode || (exports.EImageMode = {}));
7
+ })(EImageMode || (EImageMode = {}));
@@ -1,3 +1,4 @@
1
1
  export * from './image';
2
2
  export * from './papertype';
3
+ export * from './papertypeq3';
3
4
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/types/index.ts"],"names":[],"mappings":"AAAA,cAAc,SAAS,CAAA;AACvB,cAAc,aAAa,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/types/index.ts"],"names":[],"mappings":"AAAA,cAAc,SAAS,CAAA;AACvB,cAAc,aAAa,CAAA;AAC3B,cAAc,eAAe,CAAA"}
@@ -1,18 +1,3 @@
1
- "use strict";
2
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
- if (k2 === undefined) k2 = k;
4
- var desc = Object.getOwnPropertyDescriptor(m, k);
5
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
- desc = { enumerable: true, get: function() { return m[k]; } };
7
- }
8
- Object.defineProperty(o, k2, desc);
9
- }) : (function(o, m, k, k2) {
10
- if (k2 === undefined) k2 = k;
11
- o[k2] = m[k];
12
- }));
13
- var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
- for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
- };
16
- Object.defineProperty(exports, "__esModule", { value: true });
17
- __exportStar(require("./image"), exports);
18
- __exportStar(require("./papertype"), exports);
1
+ export * from './image';
2
+ export * from './papertype';
3
+ export * from './papertypeq3';
@@ -1,7 +1,4 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.PaperType = void 0;
4
- var PaperType;
1
+ export var PaperType;
5
2
  (function (PaperType) {
6
3
  /**
7
4
  * 折叠黑标纸
@@ -15,4 +12,4 @@ var PaperType;
15
12
  * 不干胶缝隙纸
16
13
  */
17
14
  PaperType[PaperType["NO_DRY_ADHESIVE_PAPER"] = 2] = "NO_DRY_ADHESIVE_PAPER";
18
- })(PaperType = exports.PaperType || (exports.PaperType = {}));
15
+ })(PaperType || (PaperType = {}));
@@ -0,0 +1,15 @@
1
+ export declare enum PaperTypeQ3 {
2
+ /**
3
+ * 不干胶缝隙纸
4
+ */
5
+ NO_DRY_ADHESIVE_PAPER = 0,
6
+ /**
7
+ * 折叠黑标纸
8
+ */
9
+ FOLDED_BLACK_LABEL_PAPER = 1,
10
+ /**
11
+ * 连续卷筒纸
12
+ */
13
+ CONTINUOUS_REEL_PAPER = 2
14
+ }
15
+ //# sourceMappingURL=papertypeq3.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"papertypeq3.d.ts","sourceRoot":"","sources":["../../src/types/papertypeq3.ts"],"names":[],"mappings":"AACA,oBAAY,WAAW;IACrB;;OAEG;IACH,qBAAqB,IAAE;IACvB;;OAEG;IACH,wBAAwB,IAAE;IAC1B;;OAEG;IACH,qBAAqB,IAAE;CACxB"}
@@ -0,0 +1,15 @@
1
+ export var PaperTypeQ3;
2
+ (function (PaperTypeQ3) {
3
+ /**
4
+ * 不干胶缝隙纸
5
+ */
6
+ PaperTypeQ3[PaperTypeQ3["NO_DRY_ADHESIVE_PAPER"] = 0] = "NO_DRY_ADHESIVE_PAPER";
7
+ /**
8
+ * 折叠黑标纸
9
+ */
10
+ PaperTypeQ3[PaperTypeQ3["FOLDED_BLACK_LABEL_PAPER"] = 1] = "FOLDED_BLACK_LABEL_PAPER";
11
+ /**
12
+ * 连续卷筒纸
13
+ */
14
+ PaperTypeQ3[PaperTypeQ3["CONTINUOUS_REEL_PAPER"] = 2] = "CONTINUOUS_REEL_PAPER";
15
+ })(PaperTypeQ3 || (PaperTypeQ3 = {}));
package/package.json CHANGED
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "@psdk/esc",
3
- "version": "0.2.67",
3
+ "version": "0.3.1",
4
4
  "description": "psdk",
5
5
  "main": "build/index.js",
6
6
  "types": "build/index.d.ts",
7
7
  "scripts": {
8
8
  "build": "tsc",
9
- "package": "tsc && ncc build --source-map build/index.js -m -C -o dist && npx webpack",
9
+ "package": "tsc && ncc build --source-map build/index.js -m -C -o dist",
10
10
  "test": "jest",
11
11
  "docs": "npx typedoc --out dist/docs index.ts"
12
12
  },
@@ -15,42 +15,23 @@
15
15
  },
16
16
  "author": "",
17
17
  "devDependencies": {
18
- "@babel/plugin-proposal-class-properties": "^7.17.12",
19
- "@babel/plugin-proposal-decorators": "^7.17.12",
20
- "@babel/plugin-proposal-export-namespace-from": "^7.17.12",
21
- "@babel/plugin-proposal-function-sent": "^7.17.12",
22
- "@babel/plugin-proposal-numeric-separator": "^7.16.7",
23
- "@babel/plugin-proposal-object-rest-spread": "^7.18.0",
24
- "@babel/plugin-proposal-throw-expressions": "^7.16.7",
25
- "@babel/plugin-syntax-dynamic-import": "^7.8.3",
26
- "@babel/plugin-syntax-import-meta": "^7.10.4",
27
- "@babel/plugin-transform-modules-commonjs": "^7.18.0",
28
- "@babel/plugin-transform-object-assign": "^7.16.7",
29
- "@babel/plugin-transform-runtime": "^7.18.0",
30
- "@babel/preset-env": "^7.18.0",
31
- "@babel/preset-typescript": "^7.17.12",
32
- "@babel/register": "^7.17.7",
33
- "@babel/runtime-corejs3": "^7.18.0",
34
- "@types/jest": "^27.5.1",
35
- "@types/node": "^17.0.35",
36
- "@vercel/ncc": "^0.33.4",
37
- "babel-loader": "^8.2.5",
38
- "buffer": "^6.0.3",
39
- "jest": "^28.1.0",
40
- "string_decoder": "^1.3.0",
41
- "ts-jest": "^28.0.2",
42
- "typedoc": "^0.22.15",
43
- "typescript": "^4.6.4",
44
- "webpack": "^5.72.1",
45
- "webpack-cli": "^4.9.2"
18
+ "@babel/core": "^7.24.5",
19
+ "@babel/preset-env": "^7.24.5",
20
+ "@babel/preset-typescript": "^7.24.1",
21
+ "@types/jest": "^29.5.12",
22
+ "@vercel/ncc": "^0.38.1",
23
+ "babel-jest": "^29.7.0",
24
+ "jest": "^29.7.0",
25
+ "typedoc": "^0.25.13",
26
+ "typescript": "^5.4.5"
46
27
  },
47
28
  "dependencies": {
48
- "@psdk/frame-father": "0.2.67",
49
- "@psdk/frame-imageb": "0.2.67"
29
+ "@psdk/frame-father": "0.3.1",
30
+ "@psdk/frame-imageb": "0.3.1"
50
31
  },
51
32
  "files": [
52
33
  "build",
53
34
  "!build/browser/psdk*"
54
35
  ],
55
- "gitHead": "1b469612990a3efbf1a3fe4296ed13e8c8865988"
36
+ "gitHead": "e6a5cd6d59ef0ae61226a47d72fbe059a787d291"
56
37
  }