@mlightcad/cad-simple-viewer 1.4.7 → 1.4.8
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/LICENSE +21 -21
- package/README.md +88 -88
- package/dist/index.js +6014 -5042
- package/dist/index.umd.cjs +22 -22
- package/lib/app/AcApAnnotation.d.ts +46 -0
- package/lib/app/AcApAnnotation.d.ts.map +1 -0
- package/lib/app/AcApAnnotation.js +134 -0
- package/lib/app/AcApAnnotation.js.map +1 -0
- package/lib/app/AcApDocManager.d.ts +118 -6
- package/lib/app/AcApDocManager.d.ts.map +1 -1
- package/lib/app/AcApDocManager.js +162 -6
- package/lib/app/AcApDocManager.js.map +1 -1
- package/lib/app/AcApDocument.d.ts +16 -14
- package/lib/app/AcApDocument.d.ts.map +1 -1
- package/lib/app/AcApDocument.js +48 -31
- package/lib/app/AcApDocument.js.map +1 -1
- package/lib/app/AcDbOpenDatabaseOptions.d.ts +28 -0
- package/lib/app/AcDbOpenDatabaseOptions.d.ts.map +1 -0
- package/lib/app/AcDbOpenDatabaseOptions.js +2 -0
- package/lib/app/AcDbOpenDatabaseOptions.js.map +1 -0
- package/lib/app/index.d.ts +2 -0
- package/lib/app/index.d.ts.map +1 -1
- package/lib/app/index.js +2 -0
- package/lib/app/index.js.map +1 -1
- package/lib/command/AcApBaseRevCmd.d.ts +36 -0
- package/lib/command/AcApBaseRevCmd.d.ts.map +1 -0
- package/lib/command/AcApBaseRevCmd.js +68 -0
- package/lib/command/AcApBaseRevCmd.js.map +1 -0
- package/lib/command/AcApCircleCmd.d.ts +1 -0
- package/lib/command/AcApCircleCmd.d.ts.map +1 -1
- package/lib/command/AcApCircleCmd.js +4 -2
- package/lib/command/AcApCircleCmd.js.map +1 -1
- package/lib/command/AcApConvertToSvgCmd.d.ts +1 -1
- package/lib/command/AcApConvertToSvgCmd.d.ts.map +1 -1
- package/lib/command/AcApConvertToSvgCmd.js +44 -2
- package/lib/command/AcApConvertToSvgCmd.js.map +1 -1
- package/lib/command/AcApDimLinearCmd.d.ts +1 -0
- package/lib/command/AcApDimLinearCmd.d.ts.map +1 -1
- package/lib/command/AcApDimLinearCmd.js +4 -2
- package/lib/command/AcApDimLinearCmd.js.map +1 -1
- package/lib/command/AcApEraseCmd.d.ts +1 -0
- package/lib/command/AcApEraseCmd.d.ts.map +1 -1
- package/lib/command/AcApEraseCmd.js +14 -4
- package/lib/command/AcApEraseCmd.js.map +1 -1
- package/lib/command/AcApLineCmd.d.ts +1 -0
- package/lib/command/AcApLineCmd.d.ts.map +1 -1
- package/lib/command/AcApLineCmd.js +4 -2
- package/lib/command/AcApLineCmd.js.map +1 -1
- package/lib/command/AcApLogCmd.d.ts +1 -1
- package/lib/command/AcApLogCmd.d.ts.map +1 -1
- package/lib/command/AcApLogCmd.js +44 -3
- package/lib/command/AcApLogCmd.js.map +1 -1
- package/lib/command/AcApOpenCmd.d.ts +1 -1
- package/lib/command/AcApOpenCmd.d.ts.map +1 -1
- package/lib/command/AcApOpenCmd.js +42 -1
- package/lib/command/AcApOpenCmd.js.map +1 -1
- package/lib/command/AcApPanCmd.d.ts +1 -1
- package/lib/command/AcApPanCmd.d.ts.map +1 -1
- package/lib/command/AcApPanCmd.js +43 -2
- package/lib/command/AcApPanCmd.js.map +1 -1
- package/lib/command/AcApQNewCmd.d.ts +1 -1
- package/lib/command/AcApQNewCmd.d.ts.map +1 -1
- package/lib/command/AcApQNewCmd.js +44 -2
- package/lib/command/AcApQNewCmd.js.map +1 -1
- package/lib/command/AcApRectCmd.d.ts +23 -0
- package/lib/command/AcApRectCmd.d.ts.map +1 -0
- package/lib/command/AcApRectCmd.js +134 -0
- package/lib/command/AcApRectCmd.js.map +1 -0
- package/lib/command/AcApRegenCmd.d.ts +1 -1
- package/lib/command/AcApRegenCmd.d.ts.map +1 -1
- package/lib/command/AcApRegenCmd.js +42 -1
- package/lib/command/AcApRegenCmd.js.map +1 -1
- package/lib/command/AcApRevCircleCmd.d.ts +10 -0
- package/lib/command/AcApRevCircleCmd.d.ts.map +1 -0
- package/lib/command/AcApRevCircleCmd.js +83 -0
- package/lib/command/AcApRevCircleCmd.js.map +1 -0
- package/lib/command/AcApRevCloudCmd.d.ts +26 -0
- package/lib/command/AcApRevCloudCmd.d.ts.map +1 -0
- package/lib/command/AcApRevCloudCmd.js +234 -0
- package/lib/command/AcApRevCloudCmd.js.map +1 -0
- package/lib/command/AcApRevRectCmd.d.ts +10 -0
- package/lib/command/AcApRevRectCmd.d.ts.map +1 -0
- package/lib/command/AcApRevRectCmd.js +83 -0
- package/lib/command/AcApRevRectCmd.js.map +1 -0
- package/lib/command/AcApRevVisibilityCmd.d.ts +15 -0
- package/lib/command/AcApRevVisibilityCmd.d.ts.map +1 -0
- package/lib/command/AcApRevVisibilityCmd.js +90 -0
- package/lib/command/AcApRevVisibilityCmd.js.map +1 -0
- package/lib/command/AcApSelectCmd.d.ts +1 -1
- package/lib/command/AcApSelectCmd.d.ts.map +1 -1
- package/lib/command/AcApSelectCmd.js +43 -2
- package/lib/command/AcApSelectCmd.js.map +1 -1
- package/lib/command/AcApSketchCmd.d.ts +32 -0
- package/lib/command/AcApSketchCmd.d.ts.map +1 -0
- package/lib/command/AcApSketchCmd.js +171 -0
- package/lib/command/AcApSketchCmd.js.map +1 -0
- package/lib/command/AcApSwitchBgCmd.d.ts +15 -0
- package/lib/command/AcApSwitchBgCmd.d.ts.map +1 -0
- package/lib/command/AcApSwitchBgCmd.js +88 -0
- package/lib/command/AcApSwitchBgCmd.js.map +1 -0
- package/lib/command/AcApSysVarCmd.d.ts +2 -1
- package/lib/command/AcApSysVarCmd.d.ts.map +1 -1
- package/lib/command/AcApSysVarCmd.js +6 -5
- package/lib/command/AcApSysVarCmd.js.map +1 -1
- package/lib/command/AcApZoomCmd.d.ts +1 -1
- package/lib/command/AcApZoomCmd.d.ts.map +1 -1
- package/lib/command/AcApZoomCmd.js +42 -1
- package/lib/command/AcApZoomCmd.js.map +1 -1
- package/lib/command/index.d.ts +8 -0
- package/lib/command/index.d.ts.map +1 -1
- package/lib/command/index.js +8 -0
- package/lib/command/index.js.map +1 -1
- package/lib/editor/command/AcEdCommand.d.ts +81 -22
- package/lib/editor/command/AcEdCommand.d.ts.map +1 -1
- package/lib/editor/command/AcEdCommand.js +157 -15
- package/lib/editor/command/AcEdCommand.js.map +1 -1
- package/lib/editor/command/AcEdCommandIterator.d.ts +1 -1
- package/lib/editor/command/AcEdCommandIterator.d.ts.map +1 -1
- package/lib/editor/command/AcEdCommandStack.d.ts +31 -6
- package/lib/editor/command/AcEdCommandStack.d.ts.map +1 -1
- package/lib/editor/command/AcEdCommandStack.js +55 -11
- package/lib/editor/command/AcEdCommandStack.js.map +1 -1
- package/lib/editor/input/AcEditor.d.ts +14 -0
- package/lib/editor/input/AcEditor.d.ts.map +1 -1
- package/lib/editor/input/AcEditor.js +5 -1
- package/lib/editor/input/AcEditor.js.map +1 -1
- package/lib/editor/input/ui/AcEdCommandLine.d.ts.map +1 -1
- package/lib/editor/input/ui/AcEdCommandLine.js +2 -2
- package/lib/editor/input/ui/AcEdCommandLine.js.map +1 -1
- package/lib/editor/view/AcEdOpenMode.d.ts +26 -0
- package/lib/editor/view/AcEdOpenMode.d.ts.map +1 -0
- package/lib/editor/view/AcEdOpenMode.js +27 -0
- package/lib/editor/view/AcEdOpenMode.js.map +1 -0
- package/lib/editor/view/index.d.ts +2 -0
- package/lib/editor/view/index.d.ts.map +1 -1
- package/lib/editor/view/index.js +2 -0
- package/lib/editor/view/index.js.map +1 -1
- package/lib/i18n/en/command.d.ts +18 -0
- package/lib/i18n/en/command.d.ts.map +1 -1
- package/lib/i18n/en/command.js +19 -1
- package/lib/i18n/en/command.js.map +1 -1
- package/lib/i18n/en/jig.d.ts +8 -0
- package/lib/i18n/en/jig.d.ts.map +1 -1
- package/lib/i18n/en/jig.js +8 -0
- package/lib/i18n/en/jig.js.map +1 -1
- package/lib/i18n/zh/command.d.ts +18 -0
- package/lib/i18n/zh/command.d.ts.map +1 -1
- package/lib/i18n/zh/command.js +18 -0
- package/lib/i18n/zh/command.js.map +1 -1
- package/lib/i18n/zh/jig.d.ts +8 -0
- package/lib/i18n/zh/jig.d.ts.map +1 -1
- package/lib/i18n/zh/jig.js +8 -0
- package/lib/i18n/zh/jig.js.map +1 -1
- package/lib/index.d.ts +1 -0
- package/lib/index.d.ts.map +1 -1
- package/lib/index.js +1 -0
- package/lib/index.js.map +1 -1
- package/lib/plugin/AcApPlugin.d.ts +83 -0
- package/lib/plugin/AcApPlugin.d.ts.map +1 -0
- package/lib/plugin/AcApPlugin.js +2 -0
- package/lib/plugin/AcApPlugin.js.map +1 -0
- package/lib/plugin/AcApPluginExample.d.ts +23 -0
- package/lib/plugin/AcApPluginExample.d.ts.map +1 -0
- package/lib/plugin/AcApPluginExample.js +160 -0
- package/lib/plugin/AcApPluginExample.js.map +1 -0
- package/lib/plugin/AcApPluginManager.d.ts +206 -0
- package/lib/plugin/AcApPluginManager.d.ts.map +1 -0
- package/lib/plugin/AcApPluginManager.js +499 -0
- package/lib/plugin/AcApPluginManager.js.map +1 -0
- package/lib/plugin/index.d.ts +4 -0
- package/lib/plugin/index.d.ts.map +1 -0
- package/lib/plugin/index.js +4 -0
- package/lib/plugin/index.js.map +1 -0
- package/lib/view/AcTrView2d.d.ts.map +1 -1
- package/lib/view/AcTrView2d.js +8 -1
- package/lib/view/AcTrView2d.js.map +1 -1
- package/package.json +5 -5
|
@@ -13,6 +13,42 @@ var __extends = (this && this.__extends) || (function () {
|
|
|
13
13
|
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
14
14
|
};
|
|
15
15
|
})();
|
|
16
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
17
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
18
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
19
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
20
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
21
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
22
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
23
|
+
});
|
|
24
|
+
};
|
|
25
|
+
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
26
|
+
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);
|
|
27
|
+
return g.next = verb(0), g["throw"] = verb(1), g["return"] = verb(2), typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
28
|
+
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
29
|
+
function step(op) {
|
|
30
|
+
if (f) throw new TypeError("Generator is already executing.");
|
|
31
|
+
while (g && (g = 0, op[0] && (_ = 0)), _) try {
|
|
32
|
+
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;
|
|
33
|
+
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
34
|
+
switch (op[0]) {
|
|
35
|
+
case 0: case 1: t = op; break;
|
|
36
|
+
case 4: _.label++; return { value: op[1], done: false };
|
|
37
|
+
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
38
|
+
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
39
|
+
default:
|
|
40
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
41
|
+
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
42
|
+
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
43
|
+
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
44
|
+
if (t[2]) _.ops.pop();
|
|
45
|
+
_.trys.pop(); continue;
|
|
46
|
+
}
|
|
47
|
+
op = body.call(thisArg, _);
|
|
48
|
+
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
49
|
+
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
50
|
+
}
|
|
51
|
+
};
|
|
16
52
|
import { AcEdCommand } from '../command';
|
|
17
53
|
import { AcApSvgConvertor } from './AcApSvgConvertor';
|
|
18
54
|
/**
|
|
@@ -47,8 +83,14 @@ var AcApConvertToSvgCmd = /** @class */ (function (_super) {
|
|
|
47
83
|
* @param _context - The application context (unused in this command)
|
|
48
84
|
*/
|
|
49
85
|
AcApConvertToSvgCmd.prototype.execute = function (_context) {
|
|
50
|
-
|
|
51
|
-
|
|
86
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
87
|
+
var converter;
|
|
88
|
+
return __generator(this, function (_a) {
|
|
89
|
+
converter = new AcApSvgConvertor();
|
|
90
|
+
converter.convert();
|
|
91
|
+
return [2 /*return*/];
|
|
92
|
+
});
|
|
93
|
+
});
|
|
52
94
|
};
|
|
53
95
|
return AcApConvertToSvgCmd;
|
|
54
96
|
}(AcEdCommand));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AcApConvertToSvgCmd.js","sourceRoot":"","sources":["../../src/command/AcApConvertToSvgCmd.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"AcApConvertToSvgCmd.js","sourceRoot":"","sources":["../../src/command/AcApConvertToSvgCmd.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACA,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAA;AACxC,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAA;AAErD;;;;;;;;;;;;;;;;;GAiBG;AACH;IAAyC,uCAAW;IAApD;;IAaA,CAAC;IAZC;;;;;;;OAOG;IACG,qCAAO,GAAb,UAAc,QAAqB;;;;gBAC3B,SAAS,GAAG,IAAI,gBAAgB,EAAE,CAAA;gBACxC,SAAS,CAAC,OAAO,EAAE,CAAA;;;;KACpB;IACH,0BAAC;AAAD,CAAC,AAbD,CAAyC,WAAW,GAanD"}
|
|
@@ -20,6 +20,7 @@ export declare class AcApDimJig extends AcEdPreviewJig<AcGePoint3dLike> {
|
|
|
20
20
|
* Command to create one aligned dimension.
|
|
21
21
|
*/
|
|
22
22
|
export declare class AcApDimLinearCmd extends AcEdCommand {
|
|
23
|
+
constructor();
|
|
23
24
|
execute(context: AcApContext): Promise<void>;
|
|
24
25
|
private getAvaiableDimBlockName;
|
|
25
26
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AcApDimLinearCmd.d.ts","sourceRoot":"","sources":["../../src/command/AcApDimLinearCmd.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,oBAAoB,EACpB,YAAY,EAGZ,eAAe,EAChB,MAAM,uBAAuB,CAAA;AAE9B,OAAO,EAAE,WAAW,EAAkB,MAAM,QAAQ,CAAA;AACpD,OAAO,EACL,YAAY,EACZ,WAAW,
|
|
1
|
+
{"version":3,"file":"AcApDimLinearCmd.d.ts","sourceRoot":"","sources":["../../src/command/AcApDimLinearCmd.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,oBAAoB,EACpB,YAAY,EAGZ,eAAe,EAChB,MAAM,uBAAuB,CAAA;AAE9B,OAAO,EAAE,WAAW,EAAkB,MAAM,QAAQ,CAAA;AACpD,OAAO,EACL,YAAY,EACZ,WAAW,EAEX,cAAc,EAEf,MAAM,WAAW,CAAA;AAGlB,qBAAa,UAAW,SAAQ,cAAc,CAAC,eAAe,CAAC;IAC7D,OAAO,CAAC,GAAG,CAAc;IACzB,OAAO,CAAC,IAAI,CAAsB;IAClC,OAAO,CAAC,aAAa,CAAU;IAE/B;;;;OAIG;gBAED,IAAI,EAAE,YAAY,EAClB,EAAE,EAAE,YAAY,EAChB,WAAW,EAAE,eAAe,EAC5B,WAAW,EAAE,eAAe;IAW9B,IAAI,MAAM,IAAI,oBAAoB,CAEjC;IAED,MAAM,CAAC,KAAK,EAAE,eAAe;IAgB7B,GAAG;IAKH,OAAO,CAAC,cAAc;CAKvB;AAED;;GAEG;AACH,qBAAa,gBAAiB,SAAQ,WAAW;;IAMzC,OAAO,CAAC,OAAO,EAAE,WAAW;IAuClC,OAAO,CAAC,uBAAuB;CAiBhC"}
|
|
@@ -62,7 +62,7 @@ var __values = (this && this.__values) || function(o) {
|
|
|
62
62
|
};
|
|
63
63
|
import { AcDbAlignedDimension, AcDbDataGenerator } from '@mlightcad/data-model';
|
|
64
64
|
import { AcApDocManager } from '../app';
|
|
65
|
-
import { AcEdCommand, AcEdPreviewJig, AcEdPromptPointOptions } from '../editor';
|
|
65
|
+
import { AcEdCommand, AcEdOpenMode, AcEdPreviewJig, AcEdPromptPointOptions } from '../editor';
|
|
66
66
|
import { AcApI18n } from '../i18n';
|
|
67
67
|
var AcApDimJig = /** @class */ (function (_super) {
|
|
68
68
|
__extends(AcApDimJig, _super);
|
|
@@ -118,7 +118,9 @@ export { AcApDimJig };
|
|
|
118
118
|
var AcApDimLinearCmd = /** @class */ (function (_super) {
|
|
119
119
|
__extends(AcApDimLinearCmd, _super);
|
|
120
120
|
function AcApDimLinearCmd() {
|
|
121
|
-
|
|
121
|
+
var _this = _super.call(this) || this;
|
|
122
|
+
_this.mode = AcEdOpenMode.Review;
|
|
123
|
+
return _this;
|
|
122
124
|
}
|
|
123
125
|
AcApDimLinearCmd.prototype.execute = function (context) {
|
|
124
126
|
return __awaiter(this, void 0, void 0, function () {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AcApDimLinearCmd.js","sourceRoot":"","sources":["../../src/command/AcApDimLinearCmd.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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BAAkB;gBACpD,IAAI,MAAM,CAAC,SAAS,CAAC,GAAG,CAAC,IAAI,GAAG,GAAG,MAAM,EAAE,CAAC;oBAC1C,MAAM,GAAG,GAAG,CAAA;gBACd,CAAC;YACH,CAAC;;;;;;;;;QAED,OAAO,YAAK,MAAM,GAAG,CAAC,CAAE,CAAA;IAC1B,CAAC;IACH,uBAAC;AAAD,CAAC,AA9DD,CAAsC,WAAW,GA8DhD"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AcApEraseCmd.d.ts","sourceRoot":"","sources":["../../src/command/AcApEraseCmd.ts"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"AcApEraseCmd.d.ts","sourceRoot":"","sources":["../../src/command/AcApEraseCmd.ts"],"names":[],"mappings":"AAAA,OAAO,EAAkB,WAAW,EAAkB,MAAM,QAAQ,CAAA;AACpE,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAA;AAKxC;;GAEG;AACH,qBAAa,YAAa,SAAQ,WAAW;;IAM3C;;;;OAIG;IACG,OAAO,CAAC,OAAO,EAAE,WAAW;CAwBnC"}
|
|
@@ -49,9 +49,10 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
|
49
49
|
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
50
50
|
}
|
|
51
51
|
};
|
|
52
|
-
import { AcApDocManager } from '../app';
|
|
52
|
+
import { AcApAnnotation, AcApDocManager } from '../app';
|
|
53
53
|
import { AcEdCommand } from '../command';
|
|
54
54
|
import { AcEdPromptSelectionOptions } from '../editor/input/prompt';
|
|
55
|
+
import { AcEdOpenMode } from '../editor/view';
|
|
55
56
|
import { AcApI18n } from '../i18n';
|
|
56
57
|
/**
|
|
57
58
|
* Command to delete selected objects from the drawing.
|
|
@@ -59,7 +60,9 @@ import { AcApI18n } from '../i18n';
|
|
|
59
60
|
var AcApEraseCmd = /** @class */ (function (_super) {
|
|
60
61
|
__extends(AcApEraseCmd, _super);
|
|
61
62
|
function AcApEraseCmd() {
|
|
62
|
-
|
|
63
|
+
var _this = _super.call(this) || this;
|
|
64
|
+
_this.mode = AcEdOpenMode.Review;
|
|
65
|
+
return _this;
|
|
63
66
|
}
|
|
64
67
|
/**
|
|
65
68
|
* Executes the command to delete selected objects from the drawing
|
|
@@ -68,13 +71,17 @@ var AcApEraseCmd = /** @class */ (function (_super) {
|
|
|
68
71
|
*/
|
|
69
72
|
AcApEraseCmd.prototype.execute = function (context) {
|
|
70
73
|
return __awaiter(this, void 0, void 0, function () {
|
|
71
|
-
var selectionSet, message, options, ids;
|
|
74
|
+
var selectionSet, annotation, ids, message, options, ids;
|
|
72
75
|
return __generator(this, function (_a) {
|
|
73
76
|
switch (_a.label) {
|
|
74
77
|
case 0:
|
|
75
78
|
selectionSet = context.view.selectionSet;
|
|
79
|
+
annotation = new AcApAnnotation(context.doc.database);
|
|
76
80
|
if (!(selectionSet.count > 0)) return [3 /*break*/, 1];
|
|
77
|
-
context.doc.
|
|
81
|
+
ids = context.doc.openMode == AcEdOpenMode.Review
|
|
82
|
+
? annotation.filterAnnotationEntities(selectionSet.ids)
|
|
83
|
+
: selectionSet.ids;
|
|
84
|
+
context.doc.database.tables.blockTable.removeEntity(ids);
|
|
78
85
|
selectionSet.clear();
|
|
79
86
|
return [3 /*break*/, 3];
|
|
80
87
|
case 1:
|
|
@@ -84,6 +91,9 @@ var AcApEraseCmd = /** @class */ (function (_super) {
|
|
|
84
91
|
case 2:
|
|
85
92
|
ids = _a.sent();
|
|
86
93
|
if (ids && ids.length > 0) {
|
|
94
|
+
// If it is in review mode, annotation entities can be deleted only
|
|
95
|
+
if (context.doc.openMode == AcEdOpenMode.Review)
|
|
96
|
+
ids = annotation.filterAnnotationEntities(selectionSet.ids);
|
|
87
97
|
context.doc.database.tables.blockTable.removeEntity(ids);
|
|
88
98
|
selectionSet.clear();
|
|
89
99
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AcApEraseCmd.js","sourceRoot":"","sources":["../../src/command/AcApEraseCmd.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,OAAO,EAAe,cAAc,EAAE,MAAM,QAAQ,CAAA;
|
|
1
|
+
{"version":3,"file":"AcApEraseCmd.js","sourceRoot":"","sources":["../../src/command/AcApEraseCmd.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,OAAO,EAAE,cAAc,EAAe,cAAc,EAAE,MAAM,QAAQ,CAAA;AACpE,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAA;AACxC,OAAO,EAAE,0BAA0B,EAAE,MAAM,wBAAwB,CAAA;AACnE,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAA;AAC7C,OAAO,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAA;AAElC;;GAEG;AACH;IAAkC,gCAAW;IAC3C;QACE,YAAA,MAAK,WAAE,SAAA;QACP,KAAI,CAAC,IAAI,GAAG,YAAY,CAAC,MAAM,CAAA;;IACjC,CAAC;IAED;;;;OAIG;IACG,8BAAO,GAAb,UAAc,OAAoB;;;;;;wBAC1B,YAAY,GAAG,OAAO,CAAC,IAAI,CAAC,YAAY,CAAA;wBACxC,UAAU,GAAG,IAAI,cAAc,CAAC,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAA;6BACvD,CAAA,YAAY,CAAC,KAAK,GAAG,CAAC,CAAA,EAAtB,wBAAsB;wBAElB,GAAG,GACP,OAAO,CAAC,GAAG,CAAC,QAAQ,IAAI,YAAY,CAAC,MAAM;4BACzC,CAAC,CAAC,UAAU,CAAC,wBAAwB,CAAC,YAAY,CAAC,GAAG,CAAC;4BACvD,CAAC,CAAC,YAAY,CAAC,GAAG,CAAA;wBACtB,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,MAAM,CAAC,UAAU,CAAC,YAAY,CAAC,GAAG,CAAC,CAAA;wBACxD,YAAY,CAAC,KAAK,EAAE,CAAA;;;wBAEd,OAAO,GAAG,QAAQ,CAAC,YAAY,CAAC,OAAO,CAAC,CAAA;wBACxC,OAAO,GAAG,IAAI,0BAA0B,CAAC,OAAO,CAAC,CAAA;wBAC7C,qBAAM,cAAc,CAAC,QAAQ,CAAC,MAAM,CAAC,YAAY,CAAC,OAAO,CAAC,EAAA;;wBAAhE,GAAG,GAAG,SAA0D;wBACpE,IAAI,GAAG,IAAI,GAAG,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;4BAC1B,mEAAmE;4BACnE,IAAI,OAAO,CAAC,GAAG,CAAC,QAAQ,IAAI,YAAY,CAAC,MAAM;gCAC7C,GAAG,GAAG,UAAU,CAAC,wBAAwB,CAAC,YAAY,CAAC,GAAG,CAAC,CAAA;4BAC7D,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,MAAM,CAAC,UAAU,CAAC,YAAY,CAAC,GAAG,CAAC,CAAA;4BACxD,YAAY,CAAC,KAAK,EAAE,CAAA;wBACtB,CAAC;;;;;;KAEJ;IACH,mBAAC;AAAD,CAAC,AAnCD,CAAkC,WAAW,GAmC5C"}
|
|
@@ -16,6 +16,7 @@ export declare class AcApLineJig extends AcEdPreviewJig<AcGePoint3dLike> {
|
|
|
16
16
|
* Command to create one line.
|
|
17
17
|
*/
|
|
18
18
|
export declare class AcApLineCmd extends AcEdCommand {
|
|
19
|
+
constructor();
|
|
19
20
|
execute(context: AcApContext): Promise<void>;
|
|
20
21
|
}
|
|
21
22
|
//# sourceMappingURL=AcApLineCmd.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AcApLineCmd.d.ts","sourceRoot":"","sources":["../../src/command/AcApLineCmd.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAA;AAEjE,OAAO,EAAE,WAAW,EAAkB,MAAM,QAAQ,CAAA;AACpD,OAAO,EACL,YAAY,EACZ,WAAW,
|
|
1
|
+
{"version":3,"file":"AcApLineCmd.d.ts","sourceRoot":"","sources":["../../src/command/AcApLineCmd.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAA;AAEjE,OAAO,EAAE,WAAW,EAAkB,MAAM,QAAQ,CAAA;AACpD,OAAO,EACL,YAAY,EACZ,WAAW,EAEX,cAAc,EAEf,MAAM,WAAW,CAAA;AAGlB,qBAAa,WAAY,SAAQ,cAAc,CAAC,eAAe,CAAC;IAC9D,OAAO,CAAC,KAAK,CAAU;IAEvB;;;;OAIG;gBACS,IAAI,EAAE,YAAY,EAAE,KAAK,EAAE,eAAe;IAKtD,IAAI,MAAM,IAAI,QAAQ,CAErB;IAED,MAAM,CAAC,KAAK,EAAE,eAAe;CAG9B;AAED;;GAEG;AACH,qBAAa,WAAY,SAAQ,WAAW;;IAMpC,OAAO,CAAC,OAAO,EAAE,WAAW;CAqBnC"}
|
|
@@ -51,7 +51,7 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
|
51
51
|
};
|
|
52
52
|
import { AcDbLine } from '@mlightcad/data-model';
|
|
53
53
|
import { AcApDocManager } from '../app';
|
|
54
|
-
import { AcEdCommand, AcEdPreviewJig, AcEdPromptPointOptions } from '../editor';
|
|
54
|
+
import { AcEdCommand, AcEdOpenMode, AcEdPreviewJig, AcEdPromptPointOptions } from '../editor';
|
|
55
55
|
import { AcApI18n } from '../i18n';
|
|
56
56
|
var AcApLineJig = /** @class */ (function (_super) {
|
|
57
57
|
__extends(AcApLineJig, _super);
|
|
@@ -84,7 +84,9 @@ export { AcApLineJig };
|
|
|
84
84
|
var AcApLineCmd = /** @class */ (function (_super) {
|
|
85
85
|
__extends(AcApLineCmd, _super);
|
|
86
86
|
function AcApLineCmd() {
|
|
87
|
-
|
|
87
|
+
var _this = _super.call(this) || this;
|
|
88
|
+
_this.mode = AcEdOpenMode.Write;
|
|
89
|
+
return _this;
|
|
88
90
|
}
|
|
89
91
|
AcApLineCmd.prototype.execute = function (context) {
|
|
90
92
|
return __awaiter(this, void 0, void 0, function () {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AcApLineCmd.js","sourceRoot":"","sources":["../../src/command/AcApLineCmd.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,OAAO,EAAE,QAAQ,EAAmB,MAAM,uBAAuB,CAAA;AAEjE,OAAO,EAAe,cAAc,EAAE,MAAM,QAAQ,CAAA;AACpD,OAAO,EAEL,WAAW,EACX,cAAc,EACd,sBAAsB,EACvB,MAAM,WAAW,CAAA;AAClB,OAAO,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAA;AAElC;IAAiC,+BAA+B;IAG9D;;;;OAIG;IACH,qBAAY,IAAkB,EAAE,KAAsB;QACpD,YAAA,MAAK,YAAC,IAAI,CAAC,SAAA;QACX,KAAI,CAAC,KAAK,GAAG,IAAI,QAAQ,CAAC,KAAK,EAAE,KAAK,CAAC,CAAA;;IACzC,CAAC;IAED,sBAAI,+BAAM;aAAV;YACE,OAAO,IAAI,CAAC,KAAK,CAAA;QACnB,CAAC;;;OAAA;IAED,4BAAM,GAAN,UAAO,KAAsB;QAC3B,IAAI,CAAC,KAAK,CAAC,QAAQ,GAAG,KAAK,CAAA;IAC7B,CAAC;IACH,kBAAC;AAAD,CAAC,AApBD,CAAiC,cAAc,GAoB9C;;AAED;;GAEG;AACH;IAAiC,+BAAW;
|
|
1
|
+
{"version":3,"file":"AcApLineCmd.js","sourceRoot":"","sources":["../../src/command/AcApLineCmd.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,OAAO,EAAE,QAAQ,EAAmB,MAAM,uBAAuB,CAAA;AAEjE,OAAO,EAAe,cAAc,EAAE,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IAAI,CAAA;wBACnC,cAAc,CAAC,YAAY,GAAG,IAAI,CAAA;wBAEhC,qBAAM,cAAc,CAAC,QAAQ,CAAC,MAAM,CAAC,QAAQ,CAAC,cAAc,CAAC,EAAA;;wBADzD,QAAQ,GACZ,SAA6D;wBAEzD,EAAE,GAAG,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAA;wBACzB,IAAI,GAAG,IAAI,QAAQ,CAAC,UAAU,EAAE,QAAQ,CAAC,CAAA;wBAC/C,EAAE,CAAC,MAAM,CAAC,UAAU,CAAC,UAAU,CAAC,YAAY,CAAC,IAAI,CAAC,CAAA;;;;;KACnD;IACH,kBAAC;AAAD,CAAC,AA3BD,CAAiC,WAAW,GA2B3C"}
|
|
@@ -5,7 +5,7 @@ import { AcEdCommand } from '../command';
|
|
|
5
5
|
* @internal
|
|
6
6
|
*/
|
|
7
7
|
export declare class AcApLogCmd extends AcEdCommand {
|
|
8
|
-
execute(context: AcApContext): void
|
|
8
|
+
execute(context: AcApContext): Promise<void>;
|
|
9
9
|
private printSelectionSet;
|
|
10
10
|
private printStats;
|
|
11
11
|
private printPerformanceData;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AcApLogCmd.d.ts","sourceRoot":"","sources":["../../src/command/AcApLogCmd.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,MAAM,QAAQ,CAAA;AACpC,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAA;AAGxC;;;GAGG;AACH,qBAAa,UAAW,SAAQ,WAAW;
|
|
1
|
+
{"version":3,"file":"AcApLogCmd.d.ts","sourceRoot":"","sources":["../../src/command/AcApLogCmd.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,MAAM,QAAQ,CAAA;AACpC,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAA;AAGxC;;;GAGG;AACH,qBAAa,UAAW,SAAQ,WAAW;IACnC,OAAO,CAAC,OAAO,EAAE,WAAW;IAMlC,OAAO,CAAC,iBAAiB;IAQzB,OAAO,CAAC,UAAU;IAqDlB,OAAO,CAAC,oBAAoB;CAG7B"}
|
|
@@ -13,6 +13,42 @@ var __extends = (this && this.__extends) || (function () {
|
|
|
13
13
|
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
14
14
|
};
|
|
15
15
|
})();
|
|
16
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
17
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
18
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
19
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
20
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
21
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
22
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
23
|
+
});
|
|
24
|
+
};
|
|
25
|
+
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
26
|
+
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);
|
|
27
|
+
return g.next = verb(0), g["throw"] = verb(1), g["return"] = verb(2), typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
28
|
+
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
29
|
+
function step(op) {
|
|
30
|
+
if (f) throw new TypeError("Generator is already executing.");
|
|
31
|
+
while (g && (g = 0, op[0] && (_ = 0)), _) try {
|
|
32
|
+
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;
|
|
33
|
+
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
34
|
+
switch (op[0]) {
|
|
35
|
+
case 0: case 1: t = op; break;
|
|
36
|
+
case 4: _.label++; return { value: op[1], done: false };
|
|
37
|
+
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
38
|
+
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
39
|
+
default:
|
|
40
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
41
|
+
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
42
|
+
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
43
|
+
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
44
|
+
if (t[2]) _.ops.pop();
|
|
45
|
+
_.trys.pop(); continue;
|
|
46
|
+
}
|
|
47
|
+
op = body.call(thisArg, _);
|
|
48
|
+
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
49
|
+
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
50
|
+
}
|
|
51
|
+
};
|
|
16
52
|
import { AcCmPerformanceCollector } from '@mlightcad/data-model';
|
|
17
53
|
import { AcEdCommand } from '../command';
|
|
18
54
|
/**
|
|
@@ -25,9 +61,14 @@ var AcApLogCmd = /** @class */ (function (_super) {
|
|
|
25
61
|
return _super !== null && _super.apply(this, arguments) || this;
|
|
26
62
|
}
|
|
27
63
|
AcApLogCmd.prototype.execute = function (context) {
|
|
28
|
-
this
|
|
29
|
-
|
|
30
|
-
|
|
64
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
65
|
+
return __generator(this, function (_a) {
|
|
66
|
+
this.printSelectionSet(context);
|
|
67
|
+
this.printStats(context);
|
|
68
|
+
this.printPerformanceData();
|
|
69
|
+
return [2 /*return*/];
|
|
70
|
+
});
|
|
71
|
+
});
|
|
31
72
|
};
|
|
32
73
|
AcApLogCmd.prototype.printSelectionSet = function (context) {
|
|
33
74
|
var modelSpace = context.doc.database.tables.blockTable.modelSpace;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AcApLogCmd.js","sourceRoot":"","sources":["../../src/command/AcApLogCmd.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"AcApLogCmd.js","sourceRoot":"","sources":["../../src/command/AcApLogCmd.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,OAAO,EAAE,wBAAwB,EAAE,MAAM,uBAAuB,CAAA;AAGhE,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAA;AAGxC;;;GAGG;AACH;IAAgC,8BAAW;IAA3C;;IAuEA,CAAC;IAtEO,4BAAO,GAAb,UAAc,OAAoB;;;gBAChC,IAAI,CAAC,iBAAiB,CAAC,OAAO,CAAC,CAAA;gBAC/B,IAAI,CAAC,UAAU,CAAC,OAAO,CAAC,CAAA;gBACxB,IAAI,CAAC,oBAAoB,EAAE,CAAA;;;;KAC5B;IAEO,sCAAiB,GAAzB,UAA0B,OAAoB;QAC5C,IAAM,UAAU,GAAG,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,MAAM,CAAC,UAAU,CAAC,UAAU,CAAA;QACpE,OAAO,CAAC,IAAI,CAAC,YAAY,CAAC,GAAG,CAAC,OAAO,CAAC,UAAA,EAAE;YACtC,IAAM,MAAM,GAAG,UAAU,CAAC,OAAO,CAAC,EAAE,CAAC,CAAA;YACrC,IAAI,MAAM;gBAAE,OAAO,CAAC,GAAG,CAAC,MAAM,CAAC,CAAA;QACjC,CAAC,CAAC,CAAA;IACJ,CAAC;IAEO,+BAAU,GAAlB,UAAmB,OAAoB;QACrC,IAAM,OAAO,GAAI,OAAO,CAAC,IAAmB,CAAC,KAAK,CAAC,OAAO,CAAA;QAC1D,OAAO,CAAC,GAAG,CAAC,0CAA0C,CAAC,CAAA;gCAC9C,KAAK;YACZ,OAAO,CAAC,KAAK,CAAC,k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AgB,EAAE,MAAM,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC;gBACtC,YAAY,EAAE,MAAM,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC;gBAClC,gBAAgB,EAAE,CAAC,MAAM,CAAC,OAAO,CAAC,SAAS,CAAC,QAAQ,GAAG,IAAI,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC;gBACvE,oBAAoB,EAAE,CAAC,MAAM,CAAC,OAAO,CAAC,SAAS,CAAC,OAAO,GAAG,IAAI,CAAC,CAAC,OAAO,CACrE,CAAC,CACF;aACF,CAAC,CAAA;YACF,OAAO,CAAC,KAAK,CAAC,IAAI,CAAC,CAAA;YACnB,OAAO,CAAC,QAAQ,EAAE,CAAA;;QA9CpB,KAAK,IAAI,KAAK,GAAG,CAAC,EAAE,KAAK,GAAG,OAAO,CAAC,MAAM,EAAE,EAAE,KAAK;oBAA1C,KAAK;SA+Cb;IACH,CAAC;IAEO,yCAAoB,GAA5B;QACE,wBAAwB,CAAC,WAAW,EAAE,CAAC,QAAQ,EAAE,CAAA;IACnD,CAAC;IACH,iBAAC;AAAD,CAAC,AAvED,CAAgC,WAAW,GAuE1C"}
|
|
@@ -32,6 +32,6 @@ export declare class AcApOpenCmd extends AcEdCommand {
|
|
|
32
32
|
*
|
|
33
33
|
* @param _context - The current application context (not used in this command)
|
|
34
34
|
*/
|
|
35
|
-
execute(_context: AcApContext): void
|
|
35
|
+
execute(_context: AcApContext): Promise<void>;
|
|
36
36
|
}
|
|
37
37
|
//# sourceMappingURL=AcApOpenCmd.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AcApOpenCmd.d.ts","sourceRoot":"","sources":["../../src/command/AcApOpenCmd.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,QAAQ,CAAA;AACpC,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAA;AAGxC;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,qBAAa,WAAY,SAAQ,WAAW;IAC1C;;;;;;;;OAQG;
|
|
1
|
+
{"version":3,"file":"AcApOpenCmd.d.ts","sourceRoot":"","sources":["../../src/command/AcApOpenCmd.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,QAAQ,CAAA;AACpC,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAA;AAGxC;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,qBAAa,WAAY,SAAQ,WAAW;IAC1C;;;;;;;;OAQG;IACG,OAAO,CAAC,QAAQ,EAAE,WAAW;CAGpC"}
|
|
@@ -13,6 +13,42 @@ var __extends = (this && this.__extends) || (function () {
|
|
|
13
13
|
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
14
14
|
};
|
|
15
15
|
})();
|
|
16
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
17
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
18
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
19
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
20
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
21
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
22
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
23
|
+
});
|
|
24
|
+
};
|
|
25
|
+
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
26
|
+
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);
|
|
27
|
+
return g.next = verb(0), g["throw"] = verb(1), g["return"] = verb(2), typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
28
|
+
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
29
|
+
function step(op) {
|
|
30
|
+
if (f) throw new TypeError("Generator is already executing.");
|
|
31
|
+
while (g && (g = 0, op[0] && (_ = 0)), _) try {
|
|
32
|
+
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;
|
|
33
|
+
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
34
|
+
switch (op[0]) {
|
|
35
|
+
case 0: case 1: t = op; break;
|
|
36
|
+
case 4: _.label++; return { value: op[1], done: false };
|
|
37
|
+
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
38
|
+
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
39
|
+
default:
|
|
40
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
41
|
+
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
42
|
+
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
43
|
+
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
44
|
+
if (t[2]) _.ops.pop();
|
|
45
|
+
_.trys.pop(); continue;
|
|
46
|
+
}
|
|
47
|
+
op = body.call(thisArg, _);
|
|
48
|
+
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
49
|
+
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
50
|
+
}
|
|
51
|
+
};
|
|
16
52
|
import { AcEdCommand } from '../command';
|
|
17
53
|
import { eventBus } from '../editor';
|
|
18
54
|
/**
|
|
@@ -52,7 +88,12 @@ var AcApOpenCmd = /** @class */ (function (_super) {
|
|
|
52
88
|
* @param _context - The current application context (not used in this command)
|
|
53
89
|
*/
|
|
54
90
|
AcApOpenCmd.prototype.execute = function (_context) {
|
|
55
|
-
|
|
91
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
92
|
+
return __generator(this, function (_a) {
|
|
93
|
+
eventBus.emit('open-file', {});
|
|
94
|
+
return [2 /*return*/];
|
|
95
|
+
});
|
|
96
|
+
});
|
|
56
97
|
};
|
|
57
98
|
return AcApOpenCmd;
|
|
58
99
|
}(AcEdCommand));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AcApOpenCmd.js","sourceRoot":"","sources":["../../src/command/AcApOpenCmd.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"AcApOpenCmd.js","sourceRoot":"","sources":["../../src/command/AcApOpenCmd.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACA,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAA;AACxC,OAAO,EAAE,QAAQ,EAAE,MAAM,WAAW,CAAA;AAEpC;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH;IAAiC,+BAAW;IAA5C;;IAaA,CAAC;IAZC;;;;;;;;OAQG;IACG,6BAAO,GAAb,UAAc,QAAqB;;;gBACjC,QAAQ,CAAC,IAAI,CAAC,WAAW,EAAE,EAAE,CAAC,CAAA;;;;KAC/B;IACH,kBAAC;AAAD,CAAC,AAbD,CAAiC,WAAW,GAa3C"}
|
|
@@ -26,6 +26,6 @@ export declare class AcApPanCmd extends AcEdCommand {
|
|
|
26
26
|
*
|
|
27
27
|
* @param context - The application context containing the view
|
|
28
28
|
*/
|
|
29
|
-
execute(context: AcApContext): void
|
|
29
|
+
execute(context: AcApContext): Promise<void>;
|
|
30
30
|
}
|
|
31
31
|
//# sourceMappingURL=AcApPanCmd.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AcApPanCmd.d.ts","sourceRoot":"","sources":["../../src/command/AcApPanCmd.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,QAAQ,CAAA;AACpC,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAA;AAGxC;;;;;;;;;;;;;;;;GAgBG;AACH,qBAAa,UAAW,SAAQ,WAAW;IACzC;;;;;;;OAOG;
|
|
1
|
+
{"version":3,"file":"AcApPanCmd.d.ts","sourceRoot":"","sources":["../../src/command/AcApPanCmd.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,QAAQ,CAAA;AACpC,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAA;AAGxC;;;;;;;;;;;;;;;;GAgBG;AACH,qBAAa,UAAW,SAAQ,WAAW;IACzC;;;;;;;OAOG;IACG,OAAO,CAAC,OAAO,EAAE,WAAW;CAInC"}
|
|
@@ -13,6 +13,42 @@ var __extends = (this && this.__extends) || (function () {
|
|
|
13
13
|
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
14
14
|
};
|
|
15
15
|
})();
|
|
16
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
17
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
18
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
19
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
20
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
21
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
22
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
23
|
+
});
|
|
24
|
+
};
|
|
25
|
+
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
26
|
+
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);
|
|
27
|
+
return g.next = verb(0), g["throw"] = verb(1), g["return"] = verb(2), typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
28
|
+
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
29
|
+
function step(op) {
|
|
30
|
+
if (f) throw new TypeError("Generator is already executing.");
|
|
31
|
+
while (g && (g = 0, op[0] && (_ = 0)), _) try {
|
|
32
|
+
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;
|
|
33
|
+
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
34
|
+
switch (op[0]) {
|
|
35
|
+
case 0: case 1: t = op; break;
|
|
36
|
+
case 4: _.label++; return { value: op[1], done: false };
|
|
37
|
+
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
38
|
+
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
39
|
+
default:
|
|
40
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
41
|
+
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
42
|
+
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
43
|
+
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
44
|
+
if (t[2]) _.ops.pop();
|
|
45
|
+
_.trys.pop(); continue;
|
|
46
|
+
}
|
|
47
|
+
op = body.call(thisArg, _);
|
|
48
|
+
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
49
|
+
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
50
|
+
}
|
|
51
|
+
};
|
|
16
52
|
import { AcEdCommand } from '../command';
|
|
17
53
|
import { AcEdCorsorType, AcEdViewMode } from '../editor';
|
|
18
54
|
/**
|
|
@@ -46,8 +82,13 @@ var AcApPanCmd = /** @class */ (function (_super) {
|
|
|
46
82
|
* @param context - The application context containing the view
|
|
47
83
|
*/
|
|
48
84
|
AcApPanCmd.prototype.execute = function (context) {
|
|
49
|
-
|
|
50
|
-
|
|
85
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
86
|
+
return __generator(this, function (_a) {
|
|
87
|
+
context.view.mode = AcEdViewMode.PAN;
|
|
88
|
+
context.view.setCursor(AcEdCorsorType.Grab);
|
|
89
|
+
return [2 /*return*/];
|
|
90
|
+
});
|
|
91
|
+
});
|
|
51
92
|
};
|
|
52
93
|
return AcApPanCmd;
|
|
53
94
|
}(AcEdCommand));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AcApPanCmd.js","sourceRoot":"","sources":["../../src/command/AcApPanCmd.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"AcApPanCmd.js","sourceRoot":"","sources":["../../src/command/AcApPanCmd.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACA,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAA;AACxC,OAAO,EAAE,cAAc,EAAE,YAAY,EAAE,MAAM,WAAW,CAAA;AAExD;;;;;;;;;;;;;;;;GAgBG;AACH;IAAgC,8BAAW;IAA3C;;IAaA,CAAC;IAZC;;;;;;;OAOG;IACG,4BAAO,GAAb,UAAc,OAAoB;;;gBAChC,OAAO,CAAC,IAAI,CAAC,IAAI,GAAG,YAAY,CAAC,GAAG,CAAA;gBACpC,OAAO,CAAC,IAAI,CAAC,SAAS,CAAC,cAAc,CAAC,IAAI,CAAC,CAAA;;;;KAC5C;IACH,iBAAC;AAAD,CAAC,AAbD,CAAgC,WAAW,GAa1C"}
|
|
@@ -27,6 +27,6 @@ export declare class AcApQNewCmd extends AcEdCommand {
|
|
|
27
27
|
*
|
|
28
28
|
* @param _context - The application context (unused in this command)
|
|
29
29
|
*/
|
|
30
|
-
execute(_context: AcApContext): void
|
|
30
|
+
execute(_context: AcApContext): Promise<void>;
|
|
31
31
|
}
|
|
32
32
|
//# sourceMappingURL=AcApQNewCmd.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AcApQNewCmd.d.ts","sourceRoot":"","sources":["../../src/command/AcApQNewCmd.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,QAAQ,CAAA;AAEpC,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAA;AAExC;;;;;;;;;;;;;;;;;GAiBG;AACH,qBAAa,WAAY,SAAQ,WAAW;IAC1C;;;;;;;OAOG;
|
|
1
|
+
{"version":3,"file":"AcApQNewCmd.d.ts","sourceRoot":"","sources":["../../src/command/AcApQNewCmd.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,QAAQ,CAAA;AAEpC,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAA;AAExC;;;;;;;;;;;;;;;;;GAiBG;AACH,qBAAa,WAAY,SAAQ,WAAW;IAC1C;;;;;;;OAOG;IACG,OAAO,CAAC,QAAQ,EAAE,WAAW;CAIpC"}
|
|
@@ -13,6 +13,42 @@ var __extends = (this && this.__extends) || (function () {
|
|
|
13
13
|
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
14
14
|
};
|
|
15
15
|
})();
|
|
16
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
17
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
18
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
19
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
20
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
21
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
22
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
23
|
+
});
|
|
24
|
+
};
|
|
25
|
+
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
26
|
+
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);
|
|
27
|
+
return g.next = verb(0), g["throw"] = verb(1), g["return"] = verb(2), typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
28
|
+
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
29
|
+
function step(op) {
|
|
30
|
+
if (f) throw new TypeError("Generator is already executing.");
|
|
31
|
+
while (g && (g = 0, op[0] && (_ = 0)), _) try {
|
|
32
|
+
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;
|
|
33
|
+
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
34
|
+
switch (op[0]) {
|
|
35
|
+
case 0: case 1: t = op; break;
|
|
36
|
+
case 4: _.label++; return { value: op[1], done: false };
|
|
37
|
+
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
38
|
+
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
39
|
+
default:
|
|
40
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
41
|
+
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
42
|
+
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
43
|
+
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
44
|
+
if (t[2]) _.ops.pop();
|
|
45
|
+
_.trys.pop(); continue;
|
|
46
|
+
}
|
|
47
|
+
op = body.call(thisArg, _);
|
|
48
|
+
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
49
|
+
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
50
|
+
}
|
|
51
|
+
};
|
|
16
52
|
import { AcApDocManager } from '../app';
|
|
17
53
|
import { AcEdCommand } from '../command';
|
|
18
54
|
/**
|
|
@@ -47,8 +83,14 @@ var AcApQNewCmd = /** @class */ (function (_super) {
|
|
|
47
83
|
* @param _context - The application context (unused in this command)
|
|
48
84
|
*/
|
|
49
85
|
AcApQNewCmd.prototype.execute = function (_context) {
|
|
50
|
-
|
|
51
|
-
|
|
86
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
87
|
+
var baseUrl;
|
|
88
|
+
return __generator(this, function (_a) {
|
|
89
|
+
baseUrl = AcApDocManager.instance.baseUrl;
|
|
90
|
+
AcApDocManager.instance.openUrl(baseUrl + 'templates/acadiso.dxf');
|
|
91
|
+
return [2 /*return*/];
|
|
92
|
+
});
|
|
93
|
+
});
|
|
52
94
|
};
|
|
53
95
|
return AcApQNewCmd;
|
|
54
96
|
}(AcEdCommand));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AcApQNewCmd.js","sourceRoot":"","sources":["../../src/command/AcApQNewCmd.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"AcApQNewCmd.js","sourceRoot":"","sources":["../../src/command/AcApQNewCmd.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACA,OAAO,EAAE,cAAc,EAAE,MAAM,QAAQ,CAAA;AACvC,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAA;AAExC;;;;;;;;;;;;;;;;;GAiBG;AACH;IAAiC,+BAAW;IAA5C;;IAaA,CAAC;IAZC;;;;;;;OAOG;IACG,6BAAO,GAAb,UAAc,QAAqB;;;;gBAC3B,OAAO,GAAG,cAAc,CAAC,QAAQ,CAAC,OAAO,CAAA;gBAC/C,cAAc,CAAC,QAAQ,CAAC,OAAO,CAAC,OAAO,GAAG,uBAAuB,CAAC,CAAA;;;;KACnE;IACH,kBAAC;AAAD,CAAC,AAbD,CAAiC,WAAW,GAa3C"}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { AcDbPolyline, AcGePoint2dLike } from '@mlightcad/data-model';
|
|
2
|
+
import { AcApContext } from '../app';
|
|
3
|
+
import { AcEdBaseView, AcEdCommand, AcEdPreviewJig } from '../editor';
|
|
4
|
+
export declare class AcApRectJig extends AcEdPreviewJig<AcGePoint2dLike> {
|
|
5
|
+
private _rect;
|
|
6
|
+
private _firstPoint;
|
|
7
|
+
/**
|
|
8
|
+
* Creates a line jig.
|
|
9
|
+
*
|
|
10
|
+
* @param view - The associated view
|
|
11
|
+
*/
|
|
12
|
+
constructor(view: AcEdBaseView, start: AcGePoint2dLike);
|
|
13
|
+
get entity(): AcDbPolyline;
|
|
14
|
+
update(secondPoint: AcGePoint2dLike): void;
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* Command to create one rectangle.
|
|
18
|
+
*/
|
|
19
|
+
export declare class AcApRectCmd extends AcEdCommand {
|
|
20
|
+
constructor();
|
|
21
|
+
execute(context: AcApContext): Promise<void>;
|
|
22
|
+
}
|
|
23
|
+
//# sourceMappingURL=AcApRectCmd.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AcApRectCmd.d.ts","sourceRoot":"","sources":["../../src/command/AcApRectCmd.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,YAAY,EAEZ,eAAe,EAChB,MAAM,uBAAuB,CAAA;AAE9B,OAAO,EAAE,WAAW,EAAkB,MAAM,QAAQ,CAAA;AACpD,OAAO,EACL,YAAY,EACZ,WAAW,EAEX,cAAc,EAEf,MAAM,WAAW,CAAA;AAqBlB,qBAAa,WAAY,SAAQ,cAAc,CAAC,eAAe,CAAC;IAC9D,OAAO,CAAC,KAAK,CAAc;IAC3B,OAAO,CAAC,WAAW,CAAa;IAEhC;;;;OAIG;gBACS,IAAI,EAAE,YAAY,EAAE,KAAK,EAAE,eAAe;IAMtD,IAAI,MAAM,IAAI,YAAY,CAEzB;IAED,MAAM,CAAC,WAAW,EAAE,eAAe;CAGpC;AAED;;GAEG;AACH,qBAAa,WAAY,SAAQ,WAAW;;IAMpC,OAAO,CAAC,OAAO,EAAE,WAAW;CAqBnC"}
|