@mlightcad/cad-pdf-plugin 1.5.5 → 1.5.7

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.
@@ -1 +1 @@
1
- {"version":3,"file":"AcApPdfPlugin.d.ts","sourceRoot":"","sources":["../src/AcApPdfPlugin.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,WAAW,EACX,UAAU,EACV,gBAAgB,EACjB,MAAM,8BAA8B,CAAA;AAKrC;;;;;GAKG;AACH,qBAAa,aAAc,YAAW,UAAU;IAC9C,kBAAkB;IAClB,IAAI,SAAc;IAClB,kBAAkB;IAClB,OAAO,SAAU;IACjB,kBAAkB;IAClB,WAAW,SAAiD;IAE5D,6EAA6E;IAC7E,OAAO,CAAC,kBAAkB,CAA6C;IAEvE;;;;;OAKG;IACH,MAAM,CAAC,QAAQ,EAAE,WAAW,EAAE,cAAc,EAAE,gBAAgB,GAAG,IAAI;IAUrE;;;;;OAKG;IACH,QAAQ,CAAC,QAAQ,EAAE,WAAW,EAAE,cAAc,EAAE,gBAAgB,GAAG,IAAI;CAMxE"}
1
+ {"version":3,"file":"AcApPdfPlugin.d.ts","sourceRoot":"","sources":["../src/AcApPdfPlugin.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,WAAW,EACX,UAAU,EACV,gBAAgB,EACjB,MAAM,8BAA8B,CAAA;AAMrC;;;;;GAKG;AACH,qBAAa,aAAc,YAAW,UAAU;IAC9C,kBAAkB;IAClB,IAAI,SAAc;IAClB,kBAAkB;IAClB,OAAO,SAAsB;IAC7B,kBAAkB;IAClB,WAAW,SAAiD;IAE5D,6EAA6E;IAC7E,OAAO,CAAC,kBAAkB,CAA6C;IAEvE;;;;;OAKG;IACH,MAAM,CAAC,QAAQ,EAAE,WAAW,EAAE,cAAc,EAAE,gBAAgB,GAAG,IAAI;IAUrE;;;;;OAKG;IACH,QAAQ,CAAC,QAAQ,EAAE,WAAW,EAAE,cAAc,EAAE,gBAAgB,GAAG,IAAI;CAMxE"}
@@ -10,6 +10,7 @@ var __values = (this && this.__values) || function(o) {
10
10
  throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined.");
11
11
  };
12
12
  import { AcEdCommandStack } from '@mlightcad/cad-simple-viewer';
13
+ import packageJson from '../package.json';
13
14
  import { AcApConvertToPdfCmd } from './AcApConvertToPdfCmd';
14
15
  import { AcApImportPdfCmd } from './AcApImportPdfCmd';
15
16
  /**
@@ -23,7 +24,7 @@ var AcApPdfPlugin = /** @class */ (function () {
23
24
  /** @inheritdoc */
24
25
  this.name = 'PdfPlugin';
25
26
  /** @inheritdoc */
26
- this.version = '1.0.0';
27
+ this.version = packageJson.version;
27
28
  /** @inheritdoc */
28
29
  this.description = 'PDF export (cpdf) and import (ipdf) commands';
29
30
  /** Commands registered in {@link onLoad} for cleanup in {@link onUnload}. */
@@ -1 +1 @@
1
- {"version":3,"file":"AcApPdfPlugin.js","sourceRoot":"","sources":["../src/AcApPdfPlugin.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,OAAO,EAGL,gBAAgB,EACjB,MAAM,8BAA8B,CAAA;AAErC,OAAO,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAA;AAC3D,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAA;AAErD;;;;;GAKG;AACH;IAAA;QACE,kBAAkB;QAClB,SAAI,GAAG,WAAW,CAAA;QAClB,kBAAkB;QAClB,YAAO,GAAG,OAAO,CAAA;QACjB,kBAAkB;QAClB,gBAAW,GAAG,8CAA8C,CAAA;QAE5D,6EAA6E;QACrE,uBAAkB,GAA2C,EAAE,CAAA;IA8BzE,CAAC;IA5BC;;;;;OAKG;IACH,8BAAM,GAAN,UAAO,QAAqB,EAAE,cAAgC;QAC5D,IAAM,KAAK,GAAG,gBAAgB,CAAC,0BAA0B,CAAA;QACzD,cAAc,CAAC,UAAU,CAAC,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,IAAI,mBAAmB,EAAE,CAAC,CAAA;QAC3E,cAAc,CAAC,UAAU,CAAC,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,IAAI,gBAAgB,EAAE,CAAC,CAAA;QACxE,IAAI,CAAC,kBAAkB,CAAC,IAAI,CAC1B,EAAE,KAAK,OAAA,EAAE,IAAI,EAAE,MAAM,EAAE,EACvB,EAAE,KAAK,OAAA,EAAE,IAAI,EAAE,MAAM,EAAE,CACxB,CAAA;IACH,CAAC;IAED;;;;;OAKG;IACH,gCAAQ,GAAR,UAAS,QAAqB,EAAE,cAAgC;;;YAC9D,KAAkB,IAAA,KAAA,SAAA,IAAI,CAAC,kBAAkB,CAAA,gBAAA,4BAAE,CAAC;gBAAvC,IAAM,GAAG,WAAA;gBACZ,cAAc,CAAC,SAAS,CAAC,GAAG,CAAC,KAAK,EAAE,GAAG,CAAC,IAAI,CAAC,CAAA;YAC/C,CAAC;;;;;;;;;QACD,IAAI,CAAC,kBAAkB,GAAG,EAAE,CAAA;IAC9B,CAAC;IACH,oBAAC;AAAD,CAAC,AAvCD,IAuCC"}
1
+ {"version":3,"file":"AcApPdfPlugin.js","sourceRoot":"","sources":["../src/AcApPdfPlugin.ts"],"names":[],"mappings":";;;;;;;;;;;AAAA,OAAO,EAGL,gBAAgB,EACjB,MAAM,8BAA8B,CAAA;AAErC,OAAO,WAAW,MAAM,iBAAiB,CAAA;AACzC,OAAO,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAA;AAC3D,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAA;AAErD;;;;;GAKG;AACH;IAAA;QACE,kBAAkB;QAClB,SAAI,GAAG,WAAW,CAAA;QAClB,kBAAkB;QAClB,YAAO,GAAG,WAAW,CAAC,OAAO,CAAA;QAC7B,kBAAkB;QAClB,gBAAW,GAAG,8CAA8C,CAAA;QAE5D,6EAA6E;QACrE,uBAAkB,GAA2C,EAAE,CAAA;IA8BzE,CAAC;IA5BC;;;;;OAKG;IACH,8BAAM,GAAN,UAAO,QAAqB,EAAE,cAAgC;QAC5D,IAAM,KAAK,GAAG,gBAAgB,CAAC,0BAA0B,CAAA;QACzD,cAAc,CAAC,UAAU,CAAC,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,IAAI,mBAAmB,EAAE,CAAC,CAAA;QAC3E,cAAc,CAAC,UAAU,CAAC,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,IAAI,gBAAgB,EAAE,CAAC,CAAA;QACxE,IAAI,CAAC,kBAAkB,CAAC,IAAI,CAC1B,EAAE,KAAK,OAAA,EAAE,IAAI,EAAE,MAAM,EAAE,EACvB,EAAE,KAAK,OAAA,EAAE,IAAI,EAAE,MAAM,EAAE,CACxB,CAAA;IACH,CAAC;IAED;;;;;OAKG;IACH,gCAAQ,GAAR,UAAS,QAAqB,EAAE,cAAgC;;;YAC9D,KAAkB,IAAA,KAAA,SAAA,IAAI,CAAC,kBAAkB,CAAA,gBAAA,4BAAE,CAAC;gBAAvC,IAAM,GAAG,WAAA;gBACZ,cAAc,CAAC,SAAS,CAAC,GAAG,CAAC,KAAK,EAAE,GAAG,CAAC,IAAI,CAAC,CAAA;YAC/C,CAAC;;;;;;;;;QACD,IAAI,CAAC,kBAAkB,GAAG,EAAE,CAAA;IAC9B,CAAC;IACH,oBAAC;AAAD,CAAC,AAvCD,IAuCC"}
@@ -0,0 +1,8 @@
1
+ import { AcApPdfPlugin } from './AcApPdfPlugin';
2
+ /**
3
+ * Creates a PDF plugin instance.
4
+ *
5
+ * @returns A loaded {@link AcApPdfPlugin} instance
6
+ */
7
+ export declare function createPdfPlugin(): Promise<AcApPdfPlugin>;
8
+ //# sourceMappingURL=createPdfPlugin.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"createPdfPlugin.d.ts","sourceRoot":"","sources":["../src/createPdfPlugin.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAA;AAE/C;;;;GAIG;AACH,wBAAsB,eAAe,2BAEpC"}
@@ -0,0 +1,50 @@
1
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
2
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
3
+ return new (P || (P = Promise))(function (resolve, reject) {
4
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
5
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
6
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
7
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
8
+ });
9
+ };
10
+ var __generator = (this && this.__generator) || function (thisArg, body) {
11
+ var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g = Object.create((typeof Iterator === "function" ? Iterator : Object).prototype);
12
+ return g.next = verb(0), g["throw"] = verb(1), g["return"] = verb(2), typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
13
+ function verb(n) { return function (v) { return step([n, v]); }; }
14
+ function step(op) {
15
+ if (f) throw new TypeError("Generator is already executing.");
16
+ while (g && (g = 0, op[0] && (_ = 0)), _) try {
17
+ if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
18
+ if (y = 0, t) op = [op[0] & 2, t.value];
19
+ switch (op[0]) {
20
+ case 0: case 1: t = op; break;
21
+ case 4: _.label++; return { value: op[1], done: false };
22
+ case 5: _.label++; y = op[1]; op = [0]; continue;
23
+ case 7: op = _.ops.pop(); _.trys.pop(); continue;
24
+ default:
25
+ if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
26
+ if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
27
+ if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
28
+ if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
29
+ if (t[2]) _.ops.pop();
30
+ _.trys.pop(); continue;
31
+ }
32
+ op = body.call(thisArg, _);
33
+ } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
34
+ if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
35
+ }
36
+ };
37
+ import { AcApPdfPlugin } from './AcApPdfPlugin';
38
+ /**
39
+ * Creates a PDF plugin instance.
40
+ *
41
+ * @returns A loaded {@link AcApPdfPlugin} instance
42
+ */
43
+ export function createPdfPlugin() {
44
+ return __awaiter(this, void 0, void 0, function () {
45
+ return __generator(this, function (_a) {
46
+ return [2 /*return*/, new AcApPdfPlugin()];
47
+ });
48
+ });
49
+ }
50
+ //# sourceMappingURL=createPdfPlugin.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"createPdfPlugin.js","sourceRoot":"","sources":["../src/createPdfPlugin.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAA;AAE/C;;;;GAIG;AACH,MAAM,UAAgB,eAAe;;;YACnC,sBAAO,IAAI,aAAa,EAAE,EAAA;;;CAC3B"}
package/lib/index.d.ts CHANGED
@@ -7,5 +7,6 @@ export { AcApConvertToPdfCmd } from './AcApConvertToPdfCmd';
7
7
  export { AcApImportPdfCmd } from './AcApImportPdfCmd';
8
8
  export { AcApPdfConvertor } from './AcApPdfConvertor';
9
9
  export { AcApPdfImportConvertor } from './AcApPdfImportConvertor';
10
- export { createPdfPlugin, PDF_PLUGIN_NAME, PDF_PLUGIN_TRIGGERS, registerLazyPdfPlugin } from './registerLazyPdfPlugin';
10
+ export { createPdfPlugin } from './createPdfPlugin';
11
+ export { PDF_PLUGIN_NAME, PDF_PLUGIN_TRIGGERS } from './register';
11
12
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAA;AAC3D,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAA;AACrD,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAA;AACrD,OAAO,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAA;AACjE,OAAO,EACL,eAAe,EACf,eAAe,EACf,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,yBAAyB,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAA;AAC3D,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAA;AACrD,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAA;AACrD,OAAO,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAA;AACjE,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAA;AACnD,OAAO,EAAE,eAAe,EAAE,mBAAmB,EAAE,MAAM,YAAY,CAAA"}
package/lib/index.js CHANGED
@@ -7,5 +7,6 @@ export { AcApConvertToPdfCmd } from './AcApConvertToPdfCmd';
7
7
  export { AcApImportPdfCmd } from './AcApImportPdfCmd';
8
8
  export { AcApPdfConvertor } from './AcApPdfConvertor';
9
9
  export { AcApPdfImportConvertor } from './AcApPdfImportConvertor';
10
- export { createPdfPlugin, PDF_PLUGIN_NAME, PDF_PLUGIN_TRIGGERS, registerLazyPdfPlugin } from './registerLazyPdfPlugin';
10
+ export { createPdfPlugin } from './createPdfPlugin';
11
+ export { PDF_PLUGIN_NAME, PDF_PLUGIN_TRIGGERS } from './register';
11
12
  //# sourceMappingURL=index.js.map
package/lib/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAA;AAC3D,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAA;AACrD,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAA;AACrD,OAAO,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAA;AACjE,OAAO,EACL,eAAe,EACf,eAAe,EACf,mBAAmB,EACnB,qBAAqB,EACtB,MAAM,yBAAyB,CAAA"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAA;AAC3D,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAA;AACrD,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAA;AACrD,OAAO,EAAE,sBAAsB,EAAE,MAAM,0BAA0B,CAAA;AACjE,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAA;AACnD,OAAO,EAAE,eAAe,EAAE,mBAAmB,EAAE,MAAM,YAAY,CAAA"}
@@ -8,18 +8,13 @@ export declare const PDF_PLUGIN_NAME = "PdfPlugin";
8
8
  * - `ipdf` — import vector geometry from PDF
9
9
  */
10
10
  export declare const PDF_PLUGIN_TRIGGERS: readonly ["cpdf", "ipdf"];
11
- /**
12
- * Creates a PDF plugin instance after loading the plugin module chunk.
13
- *
14
- * @returns A loaded {@link AcApPdfPlugin} instance
15
- */
16
- export declare function createPdfPlugin(): Promise<import("./AcApPdfPlugin").AcApPdfPlugin>;
17
11
  /**
18
12
  * Registers the PDF plugin for lazy loading.
19
13
  *
20
- * The plugin bundle is not fetched until one of its trigger commands runs.
14
+ * Import from `@mlightcad/cad-pdf-plugin/register` so the main plugin bundle
15
+ * is not pulled into the application entry chunk.
21
16
  *
22
17
  * @param pluginManager - Plugin manager that receives the lazy registration
23
18
  */
24
19
  export declare function registerLazyPdfPlugin(pluginManager: AcApPluginManager): void;
25
- //# sourceMappingURL=registerLazyPdfPlugin.d.ts.map
20
+ //# sourceMappingURL=register.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"register.d.ts","sourceRoot":"","sources":["../src/register.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,8BAA8B,CAAA;AAErE,8CAA8C;AAC9C,eAAO,MAAM,eAAe,cAAc,CAAA;AAE1C;;;;;GAKG;AACH,eAAO,MAAM,mBAAmB,2BAA4B,CAAA;AAE5D;;;;;;;GAOG;AACH,wBAAgB,qBAAqB,CAAC,aAAa,EAAE,iBAAiB,GAAG,IAAI,CAS5E"}
@@ -68,36 +68,30 @@ export var PDF_PLUGIN_NAME = 'PdfPlugin';
68
68
  * - `ipdf` — import vector geometry from PDF
69
69
  */
70
70
  export var PDF_PLUGIN_TRIGGERS = ['cpdf', 'ipdf'];
71
- /**
72
- * Creates a PDF plugin instance after loading the plugin module chunk.
73
- *
74
- * @returns A loaded {@link AcApPdfPlugin} instance
75
- */
76
- export function createPdfPlugin() {
77
- return __awaiter(this, void 0, void 0, function () {
78
- var AcApPdfPlugin;
79
- return __generator(this, function (_a) {
80
- switch (_a.label) {
81
- case 0: return [4 /*yield*/, import('./AcApPdfPlugin')];
82
- case 1:
83
- AcApPdfPlugin = (_a.sent()).AcApPdfPlugin;
84
- return [2 /*return*/, new AcApPdfPlugin()];
85
- }
86
- });
87
- });
88
- }
89
71
  /**
90
72
  * Registers the PDF plugin for lazy loading.
91
73
  *
92
- * The plugin bundle is not fetched until one of its trigger commands runs.
74
+ * Import from `@mlightcad/cad-pdf-plugin/register` so the main plugin bundle
75
+ * is not pulled into the application entry chunk.
93
76
  *
94
77
  * @param pluginManager - Plugin manager that receives the lazy registration
95
78
  */
96
79
  export function registerLazyPdfPlugin(pluginManager) {
80
+ var _this = this;
97
81
  pluginManager.registerLazyPlugin({
98
82
  name: PDF_PLUGIN_NAME,
99
83
  triggers: __spreadArray([], __read(PDF_PLUGIN_TRIGGERS), false),
100
- loader: createPdfPlugin
84
+ loader: function () { return __awaiter(_this, void 0, void 0, function () {
85
+ var createPdfPlugin;
86
+ return __generator(this, function (_a) {
87
+ switch (_a.label) {
88
+ case 0: return [4 /*yield*/, import('@mlightcad/cad-pdf-plugin')];
89
+ case 1:
90
+ createPdfPlugin = (_a.sent()).createPdfPlugin;
91
+ return [2 /*return*/, createPdfPlugin()];
92
+ }
93
+ });
94
+ }); }
101
95
  });
102
96
  }
103
- //# sourceMappingURL=registerLazyPdfPlugin.js.map
97
+ //# sourceMappingURL=register.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"register.js","sourceRoot":"","sources":["../src/register.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,8CAA8C;AAC9C,MAAM,CAAC,IAAM,eAAe,GAAG,WAAW,CAAA;AAE1C;;;;;GAKG;AACH,MAAM,CAAC,IAAM,mBAAmB,GAAG,CAAC,MAAM,EAAE,MAAM,CAAU,CAAA;AAE5D;;;;;;;GAOG;AACH,MAAM,UAAU,qBAAqB,CAAC,aAAgC;IAAtE,iBASC;IARC,aAAa,CAAC,kBAAkB,CAAC;QAC/B,IAAI,EAAE,eAAe;QACrB,QAAQ,2BAAM,mBAAmB,SAAC;QAClC,MAAM,EAAE;;;;4BACsB,qBAAM,MAAM,CAAC,2BAA2B,CAAC,EAAA;;wBAA7D,eAAe,GAAK,CAAA,SAAyC,CAAA,gBAA9C;wBACvB,sBAAO,eAAe,EAAE,EAAA;;;aACzB;KACF,CAAC,CAAA;AACJ,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mlightcad/cad-pdf-plugin",
3
- "version": "1.5.5",
3
+ "version": "1.5.7",
4
4
  "license": "MIT",
5
5
  "type": "module",
6
6
  "repository": {
@@ -13,28 +13,41 @@
13
13
  "README.md",
14
14
  "package.json"
15
15
  ],
16
- "main": "./dist/index.umd.cjs",
17
- "module": "./dist/index.js",
16
+ "main": "./dist/cad-pdf-plugin.umd.cjs",
17
+ "module": "./dist/cad-pdf-plugin.js",
18
+ "sideEffects": false,
18
19
  "types": "./lib/index.d.ts",
20
+ "typesVersions": {
21
+ "*": {
22
+ "register": [
23
+ "lib/register.d.ts"
24
+ ]
25
+ }
26
+ },
19
27
  "exports": {
20
28
  ".": {
21
29
  "types": "./lib/index.d.ts",
22
- "import": "./dist/index.js",
23
- "require": "./dist/index.umd.cjs"
30
+ "import": "./dist/cad-pdf-plugin.js",
31
+ "require": "./dist/cad-pdf-plugin.umd.cjs"
32
+ },
33
+ "./register": {
34
+ "types": "./lib/register.d.ts",
35
+ "import": "./dist/cad-pdf-plugin-register.js",
36
+ "require": "./dist/cad-pdf-plugin-register.umd.cjs"
24
37
  }
25
38
  },
26
39
  "devDependencies": {
27
- "@mlightcad/data-model": "^1.8.3",
40
+ "@mlightcad/data-model": "^1.10.0",
28
41
  "jspdf": "^4.2.1",
29
42
  "pdfjs-dist": "^5.6.205",
30
43
  "svg2pdf.js": "^2.7.0",
31
- "@mlightcad/cad-simple-viewer": "1.5.5",
32
- "@mlightcad/cad-svg-plugin": "1.5.5"
44
+ "@mlightcad/cad-svg-plugin": "1.5.7",
45
+ "@mlightcad/cad-simple-viewer": "1.5.7"
33
46
  },
34
47
  "peerDependencies": {
35
- "@mlightcad/data-model": "^1.8.3",
36
- "@mlightcad/cad-simple-viewer": "1.5.5",
37
- "@mlightcad/cad-svg-plugin": "1.5.5"
48
+ "@mlightcad/data-model": "^1.10.0",
49
+ "@mlightcad/cad-svg-plugin": "1.5.7",
50
+ "@mlightcad/cad-simple-viewer": "1.5.7"
38
51
  },
39
52
  "scripts": {
40
53
  "clean": "rimraf dist lib tsconfig.tsbuildinfo",
@@ -1,34 +0,0 @@
1
- import { AcEdCommandStack as t } from "@mlightcad/cad-simple-viewer";
2
- import { A as e, a as n } from "./index-DNe5YnrC.js";
3
- class p {
4
- constructor() {
5
- this.name = "PdfPlugin", this.version = "1.0.0", this.description = "PDF export (cpdf) and import (ipdf) commands", this.registeredCommands = [];
6
- }
7
- /**
8
- * Registers `cpdf` and `ipdf` system commands.
9
- *
10
- * @param _context - Application context (unused)
11
- * @param commandManager - Command stack used to register PDF commands
12
- */
13
- onLoad(m, o) {
14
- const d = t.SYSTEMT_COMMAND_GROUP_NAME;
15
- o.addCommand(d, "cpdf", "cpdf", new e()), o.addCommand(d, "ipdf", "ipdf", new n()), this.registeredCommands.push(
16
- { group: d, name: "cpdf" },
17
- { group: d, name: "ipdf" }
18
- );
19
- }
20
- /**
21
- * Removes commands registered in {@link onLoad}.
22
- *
23
- * @param _context - Application context (unused)
24
- * @param commandManager - Command stack used to unregister PDF commands
25
- */
26
- onUnload(m, o) {
27
- for (const d of this.registeredCommands)
28
- o.removeCmd(d.group, d.name);
29
- this.registeredCommands = [];
30
- }
31
- }
32
- export {
33
- p as AcApPdfPlugin
34
- };