@mlightcad/cad-simple-viewer 1.3.2 → 1.3.4

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/dist/index.js CHANGED
@@ -1,4 +1,4 @@
1
- import { AcDbLayout as Aa, AcCmEventManager as me, AcDbSysVarManager as us, AcGePoint3d as He, acdbHostApplicationServices as ds, AcDbOsnapMode as rc, AcGeBox2d as Ke, AcGeBox3d as Oa, AcGePoint2d as je, AcDbDatabase as sc, AcDbFileType as Hn, AcCmTransparency as Wn, AcGiLineWeight as Vr, AcCmColor as $n, AcGeGeometryUtil as ic, AcGeVector2d as Hr, deepClone as Ws, AcDbCircle as ps, AcGeMathUtil as ac, AcGeVector3d as Bt, AcDbDataGenerator as oc, AcDbAlignedDimension as fs, AcDbLine as gs, AcCmPerformanceCollector as cc, AcDbViewport as Pa, AcDbRasterImage as Da, AcDbRay as Ra, AcDbXline as Ua, AcDbDatabaseConverter as lc, createWorkerApi as hc, AcDbLinetypeTableRecord as uc, AcDbTextStyleTableRecord as dc, AcDbDimStyleTableRecord as pc, AcDbLayerTableRecord as fc, AcDbViewportTableRecord as gc, AcDbBlockTableRecord as mc, AcDbBatchProcessing as yc, AcDbRasterImageDef as bc, AcDbFace as vc, AcDbArc as xc, AcDbEllipse as wc, AcDbSpline as $s, AcDbPoint as Sc, AcDbTrace as _c, AcDbPolyline as Cc, AcDbPoly2dType as In, AcDb2dPolyline as Tc, AcDbPoly3dType as ur, AcDb3dPolyline as Ic, AcDbHatch as Ec, AcGePolyline2d as Mc, AcGeLoop2d as kc, AcGeLine2d as Lc, AcGeCircArc2d as Bc, AcGeEllipseArc2d as Ac, AcGeSpline3d as qs, AcDbTable as Oc, AcDbText as Pc, AcDbMText as Dc, AcDbLeader as Rc, AcDb3PointAngularDimension as Uc, AcDbOrdinateDimension as Fc, AcDbRadialDimension as Nc, AcDbDiametricDimension as zc, AcDbWipeout as Gc, AcDbBlockReference as jc, AcDbDxfConverter as Vc, AcDbDatabaseConverterManager as Xs } from "@mlightcad/data-model";
1
+ import { AcDbLayout as Aa, AcCmEventManager as ye, AcDbSysVarManager as us, AcGePoint3d as He, acdbHostApplicationServices as ds, AcDbOsnapMode as rc, AcGeBox2d as Ke, AcGeBox3d as Oa, AcGePoint2d as je, AcDbDatabase as sc, AcDbFileType as Hn, AcCmTransparency as Wn, AcGiLineWeight as Vr, AcCmColor as $n, AcGeGeometryUtil as ic, AcGeVector2d as Hr, deepClone as Ws, AcDbCircle as ps, AcGeMathUtil as ac, AcGeVector3d as Bt, AcDbDataGenerator as oc, AcDbAlignedDimension as fs, AcDbLine as gs, AcCmPerformanceCollector as cc, AcDbViewport as Pa, AcDbRasterImage as Da, AcDbRay as Ra, AcDbXline as Ua, AcDbDatabaseConverter as lc, createWorkerApi as hc, AcDbLinetypeTableRecord as uc, AcDbTextStyleTableRecord as dc, AcDbDimStyleTableRecord as pc, AcDbLayerTableRecord as fc, AcDbViewportTableRecord as gc, AcDbBlockTableRecord as mc, AcDbBatchProcessing as yc, AcDbRasterImageDef as bc, AcDbFace as vc, AcDbArc as xc, AcDbEllipse as wc, AcDbSpline as $s, AcDbPoint as Sc, AcDbTrace as _c, AcDbPolyline as Cc, AcDbPoly2dType as In, AcDb2dPolyline as Tc, AcDbPoly3dType as ur, AcDb3dPolyline as Ic, AcDbHatch as Ec, AcGePolyline2d as Mc, AcGeLoop2d as kc, AcGeLine2d as Lc, AcGeCircArc2d as Bc, AcGeEllipseArc2d as Ac, AcGeSpline3d as qs, AcDbTable as Oc, AcDbText as Pc, AcDbMText as Dc, AcDbLeader as Rc, AcDb3PointAngularDimension as Uc, AcDbOrdinateDimension as Fc, AcDbRadialDimension as Nc, AcDbDiametricDimension as zc, AcDbWipeout as Gc, AcDbBlockReference as jc, AcDbDxfConverter as Vc, AcDbDatabaseConverterManager as Xs } from "@mlightcad/data-model";
2
2
  import * as C from "three";
3
3
  import { BufferGeometry as Hc, BufferAttribute as Wc, ShapePath as Fa, ShapeUtils as Na, Shape as $c, LineCurve as dr, QuadraticBezierCurve as Ys, CubicBezierCurve as Zs, EllipseCurve as Ks } from "three";
4
4
  import { mergeGeometries as qc } from "three/examples/jsm/utils/BufferGeometryUtils.js";
@@ -64,9 +64,9 @@ class ve {
64
64
  constructor() {
65
65
  this.events = {
66
66
  /** Fired just before the command starts executing */
67
- commandWillStart: new me(),
67
+ commandWillStart: new ye(),
68
68
  /** Fired after the command finishes executing */
69
- commandEnded: new me()
69
+ commandEnded: new ye()
70
70
  }, this._globalName = "", this._localName = "";
71
71
  }
72
72
  /**
@@ -386,7 +386,7 @@ function Jc(r) {
386
386
  } };
387
387
  }
388
388
  const ot = Jc();
389
- function Km(r) {
389
+ function Qm(r) {
390
390
  ot.emit("message", {
391
391
  message: r,
392
392
  type: "warning"
@@ -631,7 +631,7 @@ yt._messages = {
631
631
  zh: {}
632
632
  }, yt._currentLocale = "en", yt.events = {
633
633
  /** Fired when locale changed */
634
- localeChanged: new me()
634
+ localeChanged: new ye()
635
635
  }, yt.userCmdDescription = (e) => yt.cmdDescription(Q.DEFAUT_COMMAND_GROUP_NAME, e);
636
636
  let ce = yt;
637
637
  function za(r, e) {
@@ -795,7 +795,7 @@ ce.mergeLocaleMessage("zh", {
795
795
  const Ga = (r, e) => {
796
796
  const t = `command.${r}.${e}`;
797
797
  return ce.t(t);
798
- }, Qm = (r) => Ga(Q.SYSTEMT_COMMAND_GROUP_NAME, r), Jm = (r) => Ga(Q.DEFAUT_COMMAND_GROUP_NAME, r);
798
+ }, Jm = (r) => Ga(Q.SYSTEMT_COMMAND_GROUP_NAME, r), e0 = (r) => Ga(Q.DEFAUT_COMMAND_GROUP_NAME, r);
799
799
  class cl {
800
800
  constructor(e = document.body) {
801
801
  this.container = e, this.history = [], this.historyIndex = -1, this.lastExecuted = null, this.isCmdPopupOpen = !1, this.isMsgPanelOpen = !1, this.minWidth = 420, this.widthRatio = 0.66, this.autoCompleteIndex = -1, this.injectCSS(), this.createUI(), this.bindEvents(), this.resizeHandler(), window.addEventListener("resize", () => this.resizeHandler()), ce.events.localeChanged.addEventListener(() => this.refreshLocale());
@@ -1521,13 +1521,13 @@ class nr {
1521
1521
  return this;
1522
1522
  }
1523
1523
  }
1524
- class e0 extends nr {
1524
+ class t0 extends nr {
1525
1525
  /**
1526
1526
  * Constructs a new `AcEdPromptAngleOptions` with a given prompt message.
1527
1527
  * @param message - The prompt message shown to the user.
1528
1528
  */
1529
1529
  constructor(e) {
1530
- super(e), this._useBasePoint = !1, this._useDashedLine = !1, this._useAngleBase = !1, this._defaultValue = 0, this._useDefaultValue = !1, this._allowZero = !0, this._allowNegative = !1;
1530
+ super(e), this._useBasePoint = !0, this._useDashedLine = !0, this._useAngleBase = !1, this._defaultValue = 0, this._useDefaultValue = !1, this._allowZero = !0, this._allowNegative = !1;
1531
1531
  }
1532
1532
  /**
1533
1533
  * Gets or sets the base point for the angle prompt.
@@ -1690,7 +1690,7 @@ class ml extends ys {
1690
1690
  * @param message - The message shown to the user in the prompt.
1691
1691
  */
1692
1692
  constructor(e) {
1693
- super(e), this._useBasePoint = !1, this._useDashedLine = !1, this._only2d = !1, this.allowNegative = !1;
1693
+ super(e), this._useBasePoint = !0, this._useDashedLine = !0, this._only2d = !0, this.allowNegative = !1;
1694
1694
  }
1695
1695
  /**
1696
1696
  * Gets or sets the base point for the distance prompt.
@@ -1735,10 +1735,10 @@ class ml extends ys {
1735
1735
  this.isReadOnly || (this._only2d = e);
1736
1736
  }
1737
1737
  }
1738
- class t0 extends ys {
1738
+ class n0 extends ys {
1739
1739
  // For now there are no new memebers needed
1740
1740
  }
1741
- class n0 extends ys {
1741
+ class r0 extends ys {
1742
1742
  /**
1743
1743
  * Constructs a new `AcEdPromptIntegerOptions`.
1744
1744
  *
@@ -2189,6 +2189,81 @@ class vl {
2189
2189
  return this.validateFn({ x: e, y: t });
2190
2190
  }
2191
2191
  }
2192
+ class xl {
2193
+ constructor(e) {
2194
+ this.container = null, this.baseLine = null, this.perpLineAtBase = null, this.perpLineAtCursor = null, this.connectorLine = null, this.labelEl = null, this.angleLabelEl = null, this.xAxisLine = null, this.angleSvg = null, this.anglePath = null, this.options = {}, this.view = e;
2195
+ }
2196
+ /** Returns the parent container element that holds all rubber-band HTML elements. */
2197
+ get element() {
2198
+ return this.container;
2199
+ }
2200
+ /**
2201
+ * Starts the rubber-band preview.
2202
+ * @param basePoint The starting point in world coordinates.
2203
+ */
2204
+ start(e, t) {
2205
+ this.basePoint = new He(e), this.options = t || {};
2206
+ const n = this.options.color || "#0f0";
2207
+ this.container = document.createElement("div"), this.container.style.position = "fixed", this.container.style.left = "0", this.container.style.top = "0", this.container.style.pointerEvents = "none", this.container.style.zIndex = "99999", document.body.appendChild(this.container), this.baseLine = document.createElement("div"), this.baseLine.style.position = "fixed", this.baseLine.style.borderTop = `1px solid ${n}`, this.container.appendChild(this.baseLine);
2208
+ const s = () => {
2209
+ const i = document.createElement("div");
2210
+ return i.style.position = "fixed", i.style.borderTop = `1px dashed ${n}`, this.container.appendChild(i), i;
2211
+ };
2212
+ this.options.showBaseLineOnly || (this.perpLineAtBase = s(), this.perpLineAtCursor = s(), this.connectorLine = s(), this.labelEl = document.createElement("div"), this.labelEl.style.position = "fixed", this.labelEl.style.color = n, this.labelEl.style.fontSize = "12px", this.labelEl.style.padding = "2px 4px", this.labelEl.style.borderRadius = "4px", this.container.appendChild(this.labelEl), this.xAxisLine = document.createElement("div"), this.xAxisLine.style.position = "fixed", this.xAxisLine.style.borderTop = `1px solid ${n}`, this.container.appendChild(this.xAxisLine), this.angleSvg = document.createElementNS(
2213
+ "http://www.w3.org/2000/svg",
2214
+ "svg"
2215
+ ), this.angleSvg.setAttribute(
2216
+ "style",
2217
+ "position:absolute; overflow:visible; pointer-events:none;"
2218
+ ), this.anglePath = document.createElementNS(
2219
+ "http://www.w3.org/2000/svg",
2220
+ "path"
2221
+ ), this.anglePath.setAttribute("fill", "none"), this.anglePath.setAttribute("stroke", n), this.anglePath.setAttribute("stroke-width", "1"), this.anglePath.setAttribute("stroke-dasharray", "4 4"), this.angleSvg.appendChild(this.anglePath), this.container.appendChild(this.angleSvg), this.angleLabelEl = document.createElement("div"), this.angleLabelEl.style.position = "fixed", this.angleLabelEl.style.color = n, this.angleLabelEl.style.fontSize = "12px", this.angleLabelEl.style.padding = "2px 4px", this.angleLabelEl.style.borderRadius = "4px", this.container.appendChild(this.angleLabelEl));
2222
+ }
2223
+ /**
2224
+ * Updates the rubber-band lines to a new target point.
2225
+ * @param targetPoint The current cursor position in world coordinates.
2226
+ */
2227
+ update(e) {
2228
+ if (!this.container || !this.basePoint || !this.baseLine) return;
2229
+ const t = this.view.canvas.getBoundingClientRect(), n = this.view.wcs2Cwcs(this.basePoint), s = this.view.wcs2Cwcs(e), i = t.left, a = t.top, o = (x, v, w) => {
2230
+ const S = w.x - v.x, _ = w.y - v.y, T = Math.sqrt(S * S + _ * _), k = Math.atan2(_, S) * (180 / Math.PI);
2231
+ x.style.width = `${T}px`, x.style.transformOrigin = "0 0", x.style.transform = `translate(${v.x + i}px, ${v.y + a}px) rotate(${k}deg)`;
2232
+ };
2233
+ if (o(this.baseLine, n, s), this.options.showBaseLineOnly || !this.perpLineAtBase || !this.perpLineAtCursor || !this.connectorLine)
2234
+ return;
2235
+ const c = s.x - n.x, l = s.y - n.y, h = Math.sqrt(c * c + l * l);
2236
+ if (h === 0) {
2237
+ this.perpLineAtBase && (this.perpLineAtBase.style.width = "0px"), this.perpLineAtCursor && (this.perpLineAtCursor.style.width = "0px"), this.connectorLine && (this.connectorLine.style.width = "0px"), this.xAxisLine && (this.xAxisLine.style.width = "0px"), this.anglePath && this.anglePath.setAttribute("d", ""), this.angleLabelEl && (this.angleLabelEl.style.display = "none");
2238
+ return;
2239
+ }
2240
+ const d = this.options.perpendicularLength ?? 50, u = -l / h, f = c / h, y = { x: n.x + u * d, y: n.y + f * d }, m = { x: s.x + u * d, y: s.y + f * d };
2241
+ if (o(this.perpLineAtBase, n, y), o(this.perpLineAtCursor, s, m), o(this.connectorLine, y, m), this.labelEl) {
2242
+ const x = (y.x + m.x) / 2 + i, v = (y.y + m.y) / 2 + a - 24, w = Math.sqrt(
2243
+ (e.x - this.basePoint.x) ** 2 + (e.y - this.basePoint.y) ** 2
2244
+ );
2245
+ this.labelEl.textContent = w.toFixed(3), this.labelEl.style.left = `${x - 20}px`, this.labelEl.style.top = `${v}px`, this.labelEl.style.display = "";
2246
+ }
2247
+ if (this.xAxisLine) {
2248
+ const x = { x: n.x + h, y: n.y };
2249
+ o(this.xAxisLine, n, x);
2250
+ }
2251
+ if (this.angleSvg && this.anglePath && this.angleLabelEl) {
2252
+ const x = h, v = n.x + i, w = n.y + a, S = Math.atan2(s.y - n.y, s.x - n.x), _ = S * 180 / Math.PI, T = S / 2, k = v - x, B = w - x, A = x * 2;
2253
+ this.angleSvg.style.left = `${k}px`, this.angleSvg.style.top = `${B}px`, this.angleSvg.setAttribute("width", `${A}`), this.angleSvg.setAttribute("height", `${A}`), this.angleSvg.setAttribute("viewBox", `0 0 ${A} ${A}`);
2254
+ const G = x, j = x, Y = G + x, he = j, ne = G + x * Math.cos(S), H = j + x * Math.sin(S), $ = Math.abs(S) > Math.PI ? "1" : "0", q = S >= 0 ? "1" : "0", K = `M ${Y} ${he} A ${x} ${x} 0 ${$} ${q} ${ne} ${H}`;
2255
+ this.anglePath.setAttribute("d", K);
2256
+ const J = `${Math.abs(_).toFixed(1)}°`, ie = v + x * Math.cos(T), z = w + x * Math.sin(T);
2257
+ this.angleLabelEl.textContent = J;
2258
+ const V = 40;
2259
+ this.angleLabelEl.style.left = `${ie - V / 2}px`, this.angleLabelEl.style.top = `${z - 12}px`, this.angleLabelEl.style.display = "";
2260
+ }
2261
+ }
2262
+ /** Disposes all HTML elements associated with this rubber-band. */
2263
+ dispose() {
2264
+ this.container && this.container.remove(), this.container = null, this.baseLine = null, this.perpLineAtBase = null, this.perpLineAtCursor = null, this.connectorLine = null, this.labelEl = null, this.angleLabelEl = null, this.xAxisLine = null, this.angleSvg = null, this.anglePath = null;
2265
+ }
2266
+ }
2192
2267
  const rn = class rn {
2193
2268
  // ---------------------------------------------------------------------------
2194
2269
  // CONSTRUCTOR
@@ -2201,7 +2276,10 @@ const rn = class rn {
2201
2276
  * validation, and display mode.
2202
2277
  */
2203
2278
  constructor(e, t) {
2204
- this.lastPoint = null, this.visible = !1, this.disposed = !1, this.view = e, t.disableOSnap || (this.osnapMarkerManager = new bl(e)), this.parent = t.parent ?? document.body, this.validateFn = t.validate, this.getDynamicValue = t.getDynamicValue, this.drawPreview = t.drawPreview, this.onCommit = t.onCommit, this.onChange = t.onChange, this.onCancel = t.onCancel, this.container = document.createElement("div"), this.container.className = "ml-floating-input";
2279
+ this.lastPoint = null, this.visible = !1, this.disposed = !1, this.view = e, t.disableOSnap || (this.osnapMarkerManager = new bl(e)), t.basePoint && (this.rubberBand = new xl(this.view), this.rubberBand.start(t.basePoint, {
2280
+ color: "#0f0",
2281
+ showBaseLineOnly: t.showBaseLineOnly
2282
+ })), this.parent = t.parent ?? document.body, this.validateFn = t.validate, this.getDynamicValue = t.getDynamicValue, this.drawPreview = t.drawPreview, this.onCommit = t.onCommit, this.onChange = t.onChange, this.onCancel = t.onCancel, this.container = document.createElement("div"), this.container.className = "ml-floating-input";
2205
2283
  const n = document.createElement("span");
2206
2284
  n.className = "ml-floating-input-label", n.textContent = t.message ?? "", this.container.appendChild(n), this.inputs = new vl({
2207
2285
  parent: this.container,
@@ -2290,8 +2368,8 @@ const rn = class rn {
2290
2368
  * Safe to call multiple times; subsequent calls have no effect.
2291
2369
  */
2292
2370
  dispose() {
2293
- var e;
2294
- this.disposed || (this.disposed = !0, (e = this.osnapMarkerManager) == null || e.clear(), this.inputs.dispose(), this.removeListener(!0), this.container.remove());
2371
+ var e, t;
2372
+ this.disposed || (this.disposed = !0, (e = this.osnapMarkerManager) == null || e.clear(), this.inputs.dispose(), (t = this.rubberBand) == null || t.dispose(), this.removeListener(!0), this.container.remove());
2295
2373
  }
2296
2374
  /**
2297
2375
  * Sets position of this floating input
@@ -2338,10 +2416,10 @@ const rn = class rn {
2338
2416
  * @param e The mouse move event containing the current cursor position.
2339
2417
  */
2340
2418
  handleMouseMove(e) {
2341
- var s;
2419
+ var s, i;
2342
2420
  if (!this.visible) return;
2343
2421
  const t = this.getPosition(e), n = this.getDynamicValue(t);
2344
- this.inputs.setValue(n.raw), this.inputs.focused || this.inputs.focus(), (s = this.drawPreview) == null || s.call(this, t);
2422
+ this.inputs.setValue(n.raw), (s = this.rubberBand) == null || s.update(t), this.inputs.focused || this.inputs.focus(), (i = this.drawPreview) == null || i.call(this, t);
2345
2423
  }
2346
2424
  /**
2347
2425
  * Handles click events to commit inputs.
@@ -2431,81 +2509,6 @@ const rn = class rn {
2431
2509
  };
2432
2510
  rn.stylesInjected = !1;
2433
2511
  let Wr = rn;
2434
- class xl {
2435
- constructor(e) {
2436
- this.container = null, this.baseLine = null, this.perpLineAtBase = null, this.perpLineAtCursor = null, this.connectorLine = null, this.labelEl = null, this.angleLabelEl = null, this.xAxisLine = null, this.angleSvg = null, this.anglePath = null, this.options = {}, this.view = e;
2437
- }
2438
- /** Returns the parent container element that holds all rubber-band HTML elements. */
2439
- get element() {
2440
- return this.container;
2441
- }
2442
- /**
2443
- * Starts the rubber-band preview.
2444
- * @param basePoint The starting point in world coordinates.
2445
- */
2446
- start(e, t) {
2447
- this.basePoint = new He(e), this.options = t || {};
2448
- const n = this.options.color || "#0f0";
2449
- this.container = document.createElement("div"), this.container.style.position = "fixed", this.container.style.left = "0", this.container.style.top = "0", this.container.style.pointerEvents = "none", this.container.style.zIndex = "99999", document.body.appendChild(this.container), this.baseLine = document.createElement("div"), this.baseLine.style.position = "fixed", this.baseLine.style.borderTop = `1px solid ${n}`, this.container.appendChild(this.baseLine);
2450
- const s = () => {
2451
- const i = document.createElement("div");
2452
- return i.style.position = "fixed", i.style.borderTop = `1px dashed ${n}`, this.container.appendChild(i), i;
2453
- };
2454
- this.options.showBaseLineOnly || (this.perpLineAtBase = s(), this.perpLineAtCursor = s(), this.connectorLine = s(), this.labelEl = document.createElement("div"), this.labelEl.style.position = "fixed", this.labelEl.style.color = n, this.labelEl.style.fontSize = "12px", this.labelEl.style.padding = "2px 4px", this.labelEl.style.borderRadius = "4px", this.container.appendChild(this.labelEl), this.xAxisLine = document.createElement("div"), this.xAxisLine.style.position = "fixed", this.xAxisLine.style.borderTop = `1px solid ${n}`, this.container.appendChild(this.xAxisLine), this.angleSvg = document.createElementNS(
2455
- "http://www.w3.org/2000/svg",
2456
- "svg"
2457
- ), this.angleSvg.setAttribute(
2458
- "style",
2459
- "position:absolute; overflow:visible; pointer-events:none;"
2460
- ), this.anglePath = document.createElementNS(
2461
- "http://www.w3.org/2000/svg",
2462
- "path"
2463
- ), this.anglePath.setAttribute("fill", "none"), this.anglePath.setAttribute("stroke", n), this.anglePath.setAttribute("stroke-width", "1"), this.anglePath.setAttribute("stroke-dasharray", "4 4"), this.angleSvg.appendChild(this.anglePath), this.container.appendChild(this.angleSvg), this.angleLabelEl = document.createElement("div"), this.angleLabelEl.style.position = "fixed", this.angleLabelEl.style.color = n, this.angleLabelEl.style.fontSize = "12px", this.angleLabelEl.style.padding = "2px 4px", this.angleLabelEl.style.borderRadius = "4px", this.container.appendChild(this.angleLabelEl));
2464
- }
2465
- /**
2466
- * Updates the rubber-band lines to a new target point.
2467
- * @param targetPoint The current cursor position in world coordinates.
2468
- */
2469
- update(e) {
2470
- if (!this.container || !this.basePoint || !this.baseLine) return;
2471
- const t = this.view.canvas.getBoundingClientRect(), n = this.view.wcs2Cwcs(this.basePoint), s = this.view.wcs2Cwcs(e), i = t.left, a = t.top, o = (x, v, w) => {
2472
- const S = w.x - v.x, _ = w.y - v.y, T = Math.sqrt(S * S + _ * _), k = Math.atan2(_, S) * (180 / Math.PI);
2473
- x.style.width = `${T}px`, x.style.transformOrigin = "0 0", x.style.transform = `translate(${v.x + i}px, ${v.y + a}px) rotate(${k}deg)`;
2474
- };
2475
- if (o(this.baseLine, n, s), this.options.showBaseLineOnly || !this.perpLineAtBase || !this.perpLineAtCursor || !this.connectorLine)
2476
- return;
2477
- const c = s.x - n.x, l = s.y - n.y, h = Math.sqrt(c * c + l * l);
2478
- if (h === 0) {
2479
- this.perpLineAtBase && (this.perpLineAtBase.style.width = "0px"), this.perpLineAtCursor && (this.perpLineAtCursor.style.width = "0px"), this.connectorLine && (this.connectorLine.style.width = "0px"), this.xAxisLine && (this.xAxisLine.style.width = "0px"), this.anglePath && this.anglePath.setAttribute("d", ""), this.angleLabelEl && (this.angleLabelEl.style.display = "none");
2480
- return;
2481
- }
2482
- const d = this.options.perpendicularLength ?? 50, u = -l / h, f = c / h, y = { x: n.x + u * d, y: n.y + f * d }, m = { x: s.x + u * d, y: s.y + f * d };
2483
- if (o(this.perpLineAtBase, n, y), o(this.perpLineAtCursor, s, m), o(this.connectorLine, y, m), this.labelEl) {
2484
- const x = (y.x + m.x) / 2 + i, v = (y.y + m.y) / 2 + a - 24, w = Math.sqrt(
2485
- (e.x - this.basePoint.x) ** 2 + (e.y - this.basePoint.y) ** 2
2486
- );
2487
- this.labelEl.textContent = w.toFixed(3), this.labelEl.style.left = `${x - 20}px`, this.labelEl.style.top = `${v}px`, this.labelEl.style.display = "";
2488
- }
2489
- if (this.xAxisLine) {
2490
- const x = { x: n.x + h, y: n.y };
2491
- o(this.xAxisLine, n, x);
2492
- }
2493
- if (this.angleSvg && this.anglePath && this.angleLabelEl) {
2494
- const x = h, v = n.x + i, w = n.y + a, S = Math.atan2(s.y - n.y, s.x - n.x), _ = S * 180 / Math.PI, T = S / 2, k = v - x, B = w - x, A = x * 2;
2495
- this.angleSvg.style.left = `${k}px`, this.angleSvg.style.top = `${B}px`, this.angleSvg.setAttribute("width", `${A}`), this.angleSvg.setAttribute("height", `${A}`), this.angleSvg.setAttribute("viewBox", `0 0 ${A} ${A}`);
2496
- const G = x, j = x, Y = G + x, he = j, ne = G + x * Math.cos(S), H = j + x * Math.sin(S), $ = Math.abs(S) > Math.PI ? "1" : "0", q = S >= 0 ? "1" : "0", K = `M ${Y} ${he} A ${x} ${x} 0 ${$} ${q} ${ne} ${H}`;
2497
- this.anglePath.setAttribute("d", K);
2498
- const J = `${Math.abs(_).toFixed(1)}°`, ie = v + x * Math.cos(T), z = w + x * Math.sin(T);
2499
- this.angleLabelEl.textContent = J;
2500
- const V = 40;
2501
- this.angleLabelEl.style.left = `${ie - V / 2}px`, this.angleLabelEl.style.top = `${z - 12}px`, this.angleLabelEl.style.display = "";
2502
- }
2503
- }
2504
- /** Disposes all HTML elements associated with this rubber-band. */
2505
- dispose() {
2506
- this.container && this.container.remove(), this.container = null, this.baseLine = null, this.perpLineAtBase = null, this.perpLineAtCursor = null, this.connectorLine = null, this.labelEl = null, this.angleLabelEl = null, this.xAxisLine = null, this.angleSvg = null, this.anglePath = null;
2507
- }
2508
- }
2509
2512
  const sn = class sn {
2510
2513
  /**
2511
2514
  * Construct the manager and attach mousemove listener used for floating input
@@ -2606,8 +2609,9 @@ const sn = class sn {
2606
2609
  message: e.message,
2607
2610
  twoInputs: !1,
2608
2611
  jig: e.jig,
2609
- showBaseLineOnly: !1,
2612
+ showBaseLineOnly: !e.useDashedLine,
2610
2613
  useBasePoint: !0,
2614
+ basePoint: e.basePoint,
2611
2615
  handler: n,
2612
2616
  getDynamicValue: t
2613
2617
  });
@@ -2625,8 +2629,9 @@ const sn = class sn {
2625
2629
  message: e.message,
2626
2630
  twoInputs: !1,
2627
2631
  jig: e.jig,
2628
- showBaseLineOnly: !1,
2632
+ showBaseLineOnly: !e.useDashedLine,
2629
2633
  useBasePoint: !0,
2634
+ basePoint: e.basePoint,
2630
2635
  handler: n,
2631
2636
  getDynamicValue: t
2632
2637
  });
@@ -2700,6 +2705,7 @@ const sn = class sn {
2700
2705
  jig: e.jig,
2701
2706
  showBaseLineOnly: !e.useDashedLine,
2702
2707
  useBasePoint: e.useBasePoint,
2708
+ basePoint: e.basePoint,
2703
2709
  cleanup: t,
2704
2710
  handler: i,
2705
2711
  getDynamicValue: s,
@@ -2722,11 +2728,16 @@ const sn = class sn {
2722
2728
  isValid: u != null,
2723
2729
  value: u ?? void 0
2724
2730
  };
2725
- }, i = new Wr(this.view, {
2731
+ };
2732
+ let i;
2733
+ e.useBasePoint && (e.basePoint ? i = e.basePoint : this.lastPoint && (i = { x: this.lastPoint.x, y: this.lastPoint.y }));
2734
+ const a = new Wr(this.view, {
2726
2735
  parent: this.view.canvas,
2727
2736
  twoInputs: e.twoInputs,
2728
2737
  message: e.message,
2729
2738
  disableOSnap: e.disableOSnap,
2739
+ showBaseLineOnly: e.showBaseLineOnly,
2740
+ basePoint: i,
2730
2741
  validate: s,
2731
2742
  getDynamicValue: e.getDynamicValue,
2732
2743
  drawPreview: (d) => {
@@ -2735,24 +2746,18 @@ const sn = class sn {
2735
2746
  const f = e.getDynamicValue(d);
2736
2747
  e.jig.update(f.value), e.jig.render();
2737
2748
  }
2738
- a && (a == null || a.update(d)), (u = e.drawPreview) == null || u.call(e, d);
2749
+ (u = e.drawPreview) == null || u.call(e, d);
2739
2750
  },
2740
2751
  onCommit: (d) => {
2741
- c(d), i.lastPoint && (this.lastPoint = {
2742
- x: i.lastPoint.x,
2743
- y: i.lastPoint.y
2752
+ c(d), a.lastPoint && (this.lastPoint = {
2753
+ x: a.lastPoint.x,
2754
+ y: a.lastPoint.y
2744
2755
  });
2745
2756
  },
2746
2757
  onCancel: () => l()
2747
- });
2748
- let a;
2749
- this.lastPoint && e.useBasePoint && (a = new xl(this.view), a.start(this.lastPoint, {
2750
- color: "#0f0",
2751
- showBaseLineOnly: e.showBaseLineOnly
2752
- }));
2753
- const o = () => {
2758
+ }), o = () => {
2754
2759
  var d, u;
2755
- this.active = !1, (d = e.cleanup) == null || d.call(e), (u = e.jig) == null || u.end(), document.removeEventListener("keydown", h), a == null || a.dispose(), i.dispose();
2760
+ this.active = !1, (d = e.cleanup) == null || d.call(e), (u = e.jig) == null || u.end(), document.removeEventListener("keydown", h), a.dispose();
2756
2761
  }, c = (d) => {
2757
2762
  o(), t(d);
2758
2763
  }, l = () => {
@@ -2760,7 +2765,7 @@ const sn = class sn {
2760
2765
  }, h = (d) => {
2761
2766
  d.key === "Escape" && l();
2762
2767
  };
2763
- document.addEventListener("keydown", h), i.showAt(this.view.curMousePos);
2768
+ document.addEventListener("keydown", h), a.showAt(this.view.curMousePos);
2764
2769
  });
2765
2770
  }
2766
2771
  };
@@ -2778,7 +2783,7 @@ class wl {
2778
2783
  * Fired after a system variable is changed directly through the SETVAR command or
2779
2784
  * by entering the variable name at the command line.
2780
2785
  */
2781
- sysVarChanged: new me()
2786
+ sysVarChanged: new ye()
2782
2787
  }, this._view = e, this._cursorManager = new tl(e), this._inputManager = new $r(e);
2783
2788
  }
2784
2789
  /**
@@ -2937,9 +2942,9 @@ class Sl {
2937
2942
  constructor(e = []) {
2938
2943
  this.events = {
2939
2944
  /** Fired when entities are added to the selection */
2940
- selectionAdded: new me(),
2945
+ selectionAdded: new ye(),
2941
2946
  /** Fired when entities are removed from the selection */
2942
- selectionRemoved: new me()
2947
+ selectionRemoved: new ye()
2943
2948
  }, this._ids = new Set(e);
2944
2949
  }
2945
2950
  /**
@@ -3044,13 +3049,13 @@ class _l {
3044
3049
  constructor(e) {
3045
3050
  this.events = {
3046
3051
  /** Fired when mouse moves over the view */
3047
- mouseMove: new me(),
3052
+ mouseMove: new ye(),
3048
3053
  /** Fired when the view is resized */
3049
- viewResize: new me(),
3054
+ viewResize: new ye(),
3050
3055
  /** Fired when mouse hovers over an entity */
3051
- hover: new me(),
3056
+ hover: new ye(),
3052
3057
  /** Fired when mouse stops hovering over an entity */
3053
- unhover: new me()
3058
+ unhover: new ye()
3054
3059
  }, this._canvas = e;
3055
3060
  const t = e.getBoundingClientRect();
3056
3061
  this._bbox = new Oa(), this._width = t.width, this._height = t.height, this._curPos = new je(), this._curMousePos = new je(), this._selectionSet = new Sl(), this._editor = new wl(this), this._canvas.addEventListener("mousemove", (n) => this.onMouseMove(n)), this._canvas.addEventListener("mousedown", (n) => {
@@ -13379,11 +13384,11 @@ let fe = class {
13379
13384
  );
13380
13385
  }
13381
13386
  };
13382
- var be = /* @__PURE__ */ ((r) => (r.SHAPES = "shapes", r.BIGFONT = "bigfont", r.UNIFONT = "unifont", r))(be || {});
13387
+ var me = /* @__PURE__ */ ((r) => (r.SHAPES = "shapes", r.BIGFONT = "bigfont", r.UNIFONT = "unifont", r))(me || {});
13383
13388
  class bf {
13384
13389
  parse(e) {
13385
13390
  const t = this.parseHeader(e).split(" "), n = t[1].toLocaleLowerCase();
13386
- if (!Object.values(be).includes(n))
13391
+ if (!Object.values(me).includes(n))
13387
13392
  throw new Error(`Invalid font type: ${n}`);
13388
13393
  return {
13389
13394
  fileHeader: t[0],
@@ -13407,8 +13412,8 @@ class bf {
13407
13412
  return t.trim();
13408
13413
  }
13409
13414
  }
13410
- const Te = 10;
13411
- class vf {
13415
+ const Te = 10, vf = [13, 10, 0];
13416
+ class xf {
13412
13417
  parse(e) {
13413
13418
  try {
13414
13419
  e.readBytes(4);
@@ -13424,11 +13429,7 @@ class vf {
13424
13429
  for (const a of n)
13425
13430
  try {
13426
13431
  const o = e.readBytes(a.length);
13427
- if (o.length === a.length) {
13428
- const c = o.indexOf(0);
13429
- let l = 0;
13430
- c >= 0 && c < o.length && (l = c + 1), l < o.length && (s[a.code] = o.subarray(l));
13431
- }
13432
+ o.length === a.length && (s[a.code] = o);
13432
13433
  } catch {
13433
13434
  console.warn(`Failed to read shape data for code ${a.code}`);
13434
13435
  }
@@ -13446,7 +13447,7 @@ class vf {
13446
13447
  const a = s[0];
13447
13448
  try {
13448
13449
  const o = new TextDecoder().decode(a);
13449
- let c = o.indexOf("\0");
13450
+ let c = a.findIndex((l) => vf.includes(l));
13450
13451
  c >= 0 && (i.info = o.substring(0, c), c + 3 < a.length && (i.baseUp = a[c + 1], i.baseDown = a[c + 2], i.height = i.baseDown + i.baseUp, i.width = i.height, i.orientation = a[c + 3] === 0 ? "horizontal" : "vertical"));
13451
13452
  } catch {
13452
13453
  console.warn("Failed to parse font info block");
@@ -13467,7 +13468,7 @@ class vf {
13467
13468
  }
13468
13469
  }
13469
13470
  }
13470
- class xf {
13471
+ class wf {
13471
13472
  parse(e) {
13472
13473
  try {
13473
13474
  e.readInt16();
@@ -13558,13 +13559,13 @@ class xf {
13558
13559
  return { text: t, pos: n };
13559
13560
  }
13560
13561
  }
13561
- class wf {
13562
- parse(e) {
13562
+ let Sf = class {
13563
+ parse(r) {
13563
13564
  try {
13564
- const t = e.readInt32();
13565
- if (t <= 0)
13565
+ const e = r.readInt32();
13566
+ if (e <= 0)
13566
13567
  throw new Error("Invalid character count in font file");
13567
- const n = e.readInt16(), s = e.readBytes(n), i = {
13568
+ const t = r.readInt16(), n = r.readBytes(t), s = {
13568
13569
  data: {},
13569
13570
  info: "",
13570
13571
  baseUp: 8,
@@ -13575,31 +13576,31 @@ class wf {
13575
13576
  isExtended: !1
13576
13577
  };
13577
13578
  try {
13578
- const o = new TextDecoder().decode(s);
13579
- let c = o.indexOf("\0");
13580
- c >= 0 && (i.info = o.substring(0, c), c + 3 < s.length && (i.baseUp = s[c + 1], i.baseDown = s[c + 2], i.height = i.baseUp + i.baseDown, i.width = i.height, i.orientation = s[c + 3] === 0 ? "horizontal" : "vertical"));
13579
+ const a = new TextDecoder().decode(n);
13580
+ let o = a.indexOf("\0");
13581
+ o >= 0 && (s.info = a.substring(0, o), o + 3 < n.length && (s.baseUp = n[o + 1], s.baseDown = n[o + 2], s.height = s.baseUp + s.baseDown, s.width = s.height, s.orientation = n[o + 3] === 0 ? "horizontal" : "vertical"));
13581
13582
  } catch {
13582
13583
  console.warn("Failed to parse unifont info block");
13583
13584
  }
13584
- const a = {};
13585
- for (let o = 0; o < t - 1; o++)
13585
+ const i = {};
13586
+ for (let a = 0; a < e - 1; a++)
13586
13587
  try {
13587
- const c = e.readUint16(), l = e.readUint16();
13588
- if (l > 0) {
13589
- const h = e.readBytes(l);
13590
- if (h.length === l) {
13591
- const d = h.indexOf(0);
13592
- let u = 0;
13593
- d >= 0 && d < h.length && (u = d + 1), u < h.length && (a[c] = h.subarray(u));
13588
+ const o = r.readUint16(), c = r.readUint16();
13589
+ if (c > 0) {
13590
+ const l = r.readBytes(c);
13591
+ if (l.length === c) {
13592
+ const h = l.indexOf(0);
13593
+ let d = 0;
13594
+ h >= 0 && h < l.length && (d = h + 1), d < l.length && (i[o] = l.subarray(d));
13594
13595
  }
13595
13596
  }
13596
13597
  } catch {
13597
13598
  console.warn("Failed to read unifont character data");
13598
13599
  break;
13599
13600
  }
13600
- return i.data = a, i;
13601
- } catch (t) {
13602
- return console.error("Error parsing unifont:", t), {
13601
+ return s.data = i, s;
13602
+ } catch (e) {
13603
+ return console.error("Error parsing unifont:", e), {
13603
13604
  data: {},
13604
13605
  info: "Failed to parse font file",
13605
13606
  baseUp: 8,
@@ -13611,16 +13612,15 @@ class wf {
13611
13612
  };
13612
13613
  }
13613
13614
  }
13614
- }
13615
- let Sf = class {
13615
+ }, _f = class {
13616
13616
  static createParser(r) {
13617
13617
  switch (r) {
13618
- case be.SHAPES:
13619
- return new vf();
13620
- case be.BIGFONT:
13618
+ case me.SHAPES:
13621
13619
  return new xf();
13622
- case be.UNIFONT:
13620
+ case me.BIGFONT:
13623
13621
  return new wf();
13622
+ case me.UNIFONT:
13623
+ return new Sf();
13624
13624
  default:
13625
13625
  throw new Error(`Unsupported font type: ${r}`);
13626
13626
  }
@@ -13878,8 +13878,8 @@ class nn {
13878
13878
  return `<svg width="100%" height="100%" viewBox="${i}" preserveAspectRatio="xMidYMid meet">${a}</svg>`;
13879
13879
  }
13880
13880
  }
13881
- const _f = Math.PI / 18;
13882
- class Cf {
13881
+ const Cf = Math.PI / 18;
13882
+ class Tf {
13883
13883
  constructor(e) {
13884
13884
  this.shapeCache = /* @__PURE__ */ new Map(), this.shapeData = /* @__PURE__ */ new Map(), this.fontData = e;
13885
13885
  }
@@ -14110,13 +14110,13 @@ class Cf {
14110
14110
  let s = t, i = 0, a, o = n.scale * this.fontData.content.height, c = o;
14111
14111
  const l = n.currentPoint.clone();
14112
14112
  switch (n.currentPolyline.length > 1 && (n.polylines.push(n.currentPolyline.slice()), n.currentPolyline = []), this.fontData.header.fontType) {
14113
- case be.SHAPES:
14113
+ case me.SHAPES:
14114
14114
  s++, i = e[s];
14115
14115
  break;
14116
- case be.BIGFONT:
14116
+ case me.BIGFONT:
14117
14117
  s++, i = e[s], i === 0 && (s++, i = e[s++] << 8 | e[s++], l.x = fe.byteToSByte(e[s++]) * n.scale, l.y = fe.byteToSByte(e[s++]) * n.scale, this.fontData.content.isExtended && (c = e[s++] * n.scale), o = e[s] * n.scale);
14118
14118
  break;
14119
- case be.UNIFONT:
14119
+ case me.UNIFONT:
14120
14120
  s++, i = e[s++] << 8 | e[s++];
14121
14121
  break;
14122
14122
  }
@@ -14155,7 +14155,7 @@ class Cf {
14155
14155
  let u = h & 7;
14156
14156
  u === 0 && (u = 8), a !== 0 && u--;
14157
14157
  const f = Math.PI / 4;
14158
- let y = f * u, m = _f, x = 1;
14158
+ let y = f * u, m = Cf, x = 1;
14159
14159
  h < 0 && (m = -m, y = -y, x = -1);
14160
14160
  let v = f * d, w = v + y;
14161
14161
  v += f * i / 256 * x, w += f * a / 256 * x;
@@ -14229,13 +14229,13 @@ class Cf {
14229
14229
  break;
14230
14230
  case 7:
14231
14231
  switch (this.fontData.header.fontType) {
14232
- case be.SHAPES:
14232
+ case me.SHAPES:
14233
14233
  t++;
14234
14234
  break;
14235
- case be.BIGFONT:
14235
+ case me.BIGFONT:
14236
14236
  t++, e[t] === 0 && (t += this.fontData.content.isExtended ? 6 : 5);
14237
14237
  break;
14238
- case be.UNIFONT:
14238
+ case me.UNIFONT:
14239
14239
  t += 2;
14240
14240
  break;
14241
14241
  }
@@ -14304,30 +14304,30 @@ class Cf {
14304
14304
  return o.add(t), o;
14305
14305
  }
14306
14306
  }
14307
- class Tf {
14307
+ let If = class {
14308
14308
  /**
14309
14309
  * Creates a new ShxFont instance.
14310
14310
  * @param data - Either raw binary data of the SHX font file (ArrayBuffer) or pre-parsed font data (ShxFontData)
14311
14311
  * @throws {Error} If the font data is invalid or cannot be parsed
14312
14312
  */
14313
- constructor(e) {
14314
- if (e instanceof ArrayBuffer) {
14315
- const t = new fe(e), n = new bf().parse(t), s = Sf.createParser(n.fontType).parse(t);
14313
+ constructor(r) {
14314
+ if (r instanceof ArrayBuffer) {
14315
+ const e = new fe(r), t = new bf().parse(e), n = _f.createParser(t.fontType).parse(e);
14316
14316
  this.fontData = {
14317
- header: n,
14318
- content: s
14317
+ header: t,
14318
+ content: n
14319
14319
  };
14320
14320
  } else
14321
- this.fontData = e;
14322
- this.shapeParser = new Cf(this.fontData);
14321
+ this.fontData = r;
14322
+ this.shapeParser = new Tf(this.fontData);
14323
14323
  }
14324
14324
  /**
14325
14325
  * Return true if this font contains glyph of the specified character. Otherwise, return false.
14326
14326
  * @param char - The character to check
14327
14327
  * @returns True if this font contains glyph of the specified character. Otherwise, return false.
14328
14328
  */
14329
- hasChar(e) {
14330
- return this.fontData.content.data[e] !== void 0;
14329
+ hasChar(r) {
14330
+ return this.fontData.content.data[r] !== void 0;
14331
14331
  }
14332
14332
  /**
14333
14333
  * Gets the shape data for a specific character at a given font size.
@@ -14335,9 +14335,9 @@ class Tf {
14335
14335
  * @param size - The desired font size
14336
14336
  * @returns The shape data for the character, or undefined if the character is not found in the font
14337
14337
  */
14338
- getCharShape(e, t) {
14339
- let n = this.shapeParser.getCharShape(e, t);
14340
- return n && this.fontData.header.fontType === be.BIGFONT && (n = n.normalizeToOrigin()), n;
14338
+ getCharShape(r, e) {
14339
+ let t = this.shapeParser.getCharShape(r, e);
14340
+ return t && this.fontData.header.fontType === me.BIGFONT && (t = t.normalizeToOrigin()), t;
14341
14341
  }
14342
14342
  /**
14343
14343
  * Releases resources used by the font.
@@ -14346,11 +14346,11 @@ class Tf {
14346
14346
  release() {
14347
14347
  this.shapeParser.release();
14348
14348
  }
14349
- }
14350
- function If(r) {
14349
+ };
14350
+ function Ef(r) {
14351
14351
  return r && r.__esModule && Object.prototype.hasOwnProperty.call(r, "default") ? r.default : r;
14352
14352
  }
14353
- function Ef(r) {
14353
+ function Mf(r) {
14354
14354
  if (r.__esModule) return r;
14355
14355
  var e = r.default;
14356
14356
  if (typeof e == "function") {
@@ -14370,11 +14370,11 @@ function Ef(r) {
14370
14370
  }), t;
14371
14371
  }
14372
14372
  var Go = { exports: {} }, Bs = {}, ar = {};
14373
- ar.byteLength = Lf;
14374
- ar.toByteArray = Af;
14375
- ar.fromByteArray = Df;
14376
- var ze = [], Se = [], Mf = typeof Uint8Array < "u" ? Uint8Array : Array, Tr = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
14377
- for (var St = 0, kf = Tr.length; St < kf; ++St)
14373
+ ar.byteLength = Bf;
14374
+ ar.toByteArray = Of;
14375
+ ar.fromByteArray = Rf;
14376
+ var ze = [], Se = [], kf = typeof Uint8Array < "u" ? Uint8Array : Array, Tr = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
14377
+ for (var St = 0, Lf = Tr.length; St < Lf; ++St)
14378
14378
  ze[St] = Tr[St], Se[Tr.charCodeAt(St)] = St;
14379
14379
  Se[45] = 62;
14380
14380
  Se[95] = 63;
@@ -14387,30 +14387,30 @@ function jo(r) {
14387
14387
  var n = t === e ? 0 : 4 - t % 4;
14388
14388
  return [t, n];
14389
14389
  }
14390
- function Lf(r) {
14390
+ function Bf(r) {
14391
14391
  var e = jo(r), t = e[0], n = e[1];
14392
14392
  return (t + n) * 3 / 4 - n;
14393
14393
  }
14394
- function Bf(r, e, t) {
14394
+ function Af(r, e, t) {
14395
14395
  return (e + t) * 3 / 4 - t;
14396
14396
  }
14397
- function Af(r) {
14398
- var e, t = jo(r), n = t[0], s = t[1], i = new Mf(Bf(r, n, s)), a = 0, o = s > 0 ? n - 4 : n, c;
14397
+ function Of(r) {
14398
+ var e, t = jo(r), n = t[0], s = t[1], i = new kf(Af(r, n, s)), a = 0, o = s > 0 ? n - 4 : n, c;
14399
14399
  for (c = 0; c < o; c += 4)
14400
14400
  e = Se[r.charCodeAt(c)] << 18 | Se[r.charCodeAt(c + 1)] << 12 | Se[r.charCodeAt(c + 2)] << 6 | Se[r.charCodeAt(c + 3)], i[a++] = e >> 16 & 255, i[a++] = e >> 8 & 255, i[a++] = e & 255;
14401
14401
  return s === 2 && (e = Se[r.charCodeAt(c)] << 2 | Se[r.charCodeAt(c + 1)] >> 4, i[a++] = e & 255), s === 1 && (e = Se[r.charCodeAt(c)] << 10 | Se[r.charCodeAt(c + 1)] << 4 | Se[r.charCodeAt(c + 2)] >> 2, i[a++] = e >> 8 & 255, i[a++] = e & 255), i;
14402
14402
  }
14403
- function Of(r) {
14403
+ function Pf(r) {
14404
14404
  return ze[r >> 18 & 63] + ze[r >> 12 & 63] + ze[r >> 6 & 63] + ze[r & 63];
14405
14405
  }
14406
- function Pf(r, e, t) {
14406
+ function Df(r, e, t) {
14407
14407
  for (var n, s = [], i = e; i < t; i += 3)
14408
- n = (r[i] << 16 & 16711680) + (r[i + 1] << 8 & 65280) + (r[i + 2] & 255), s.push(Of(n));
14408
+ n = (r[i] << 16 & 16711680) + (r[i + 1] << 8 & 65280) + (r[i + 2] & 255), s.push(Pf(n));
14409
14409
  return s.join("");
14410
14410
  }
14411
- function Df(r) {
14411
+ function Rf(r) {
14412
14412
  for (var e, t = r.length, n = t % 3, s = [], i = 16383, a = 0, o = t - n; a < o; a += i)
14413
- s.push(Pf(r, a, a + i > o ? o : a + i));
14413
+ s.push(Df(r, a, a + i > o ? o : a + i));
14414
14414
  return n === 1 ? (e = r[t - 1], s.push(
14415
14415
  ze[e >> 2] + ze[e << 4 & 63] + "=="
14416
14416
  )) : n === 2 && (e = (r[t - 2] << 8) + r[t - 1], s.push(
@@ -15279,15 +15279,15 @@ Ds.prototype.write = function(r) {
15279
15279
  Ds.prototype.end = function() {
15280
15280
  return this.decoder.end();
15281
15281
  };
15282
- var Rf = typeof Object.hasOwn > "u" ? Function.call.bind(Object.prototype.hasOwnProperty) : Object.hasOwn;
15283
- function Uf(r, e) {
15282
+ var Uf = typeof Object.hasOwn > "u" ? Function.call.bind(Object.prototype.hasOwnProperty) : Object.hasOwn;
15283
+ function Ff(r, e) {
15284
15284
  for (var t in e)
15285
- Rf(e, t) && (r[t] = e[t]);
15285
+ Uf(e, t) && (r[t] = e[t]);
15286
15286
  }
15287
- var Ho = Uf, Qi = {}, Ir = {}, Er = { exports: {} };
15287
+ var Ho = Ff, Qi = {}, Ir = {}, Er = { exports: {} };
15288
15288
  /*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */
15289
15289
  var Ji;
15290
- function Ff() {
15290
+ function Nf() {
15291
15291
  return Ji || (Ji = 1, function(r, e) {
15292
15292
  var t = Bs, n = t.Buffer;
15293
15293
  function s(a, o) {
@@ -15319,10 +15319,10 @@ function Ff() {
15319
15319
  }(Er, Er.exports)), Er.exports;
15320
15320
  }
15321
15321
  var ea;
15322
- function Nf() {
15322
+ function zf() {
15323
15323
  if (ea) return Ir;
15324
15324
  ea = 1;
15325
- var r = Ff().Buffer, e = r.isEncoding || function(v) {
15325
+ var r = Nf().Buffer, e = r.isEncoding || function(v) {
15326
15326
  switch (v = "" + v, v && v.toLowerCase()) {
15327
15327
  case "hex":
15328
15328
  case "utf8":
@@ -15477,7 +15477,7 @@ function Nf() {
15477
15477
  return Ir;
15478
15478
  }
15479
15479
  var Mr, ta;
15480
- function zf() {
15480
+ function Gf() {
15481
15481
  if (ta) return Mr;
15482
15482
  ta = 1;
15483
15483
  var r = ut.Buffer;
@@ -15498,7 +15498,7 @@ function zf() {
15498
15498
  this.enc = l.encodingName, this.bomAware = l.bomAware, this.enc === "base64" ? this.encoder = i : this.enc === "utf8" ? this.encoder = c : this.enc === "cesu8" && (this.enc = "utf8", this.encoder = a, r.from("eda0bdedb2a9", "hex").toString() !== "💩" && (this.decoder = o, this.defaultCharUnicode = h.defaultCharUnicode));
15499
15499
  }
15500
15500
  e.prototype.encoder = s, e.prototype.decoder = n;
15501
- var t = Nf().StringDecoder;
15501
+ var t = zf().StringDecoder;
15502
15502
  function n(l, h) {
15503
15503
  this.decoder = new t(h.enc);
15504
15504
  }
@@ -15564,7 +15564,7 @@ function zf() {
15564
15564
  }, Mr;
15565
15565
  }
15566
15566
  var We = {}, na;
15567
- function Gf() {
15567
+ function jf() {
15568
15568
  if (na) return We;
15569
15569
  na = 1;
15570
15570
  var r = ut.Buffer;
@@ -15683,7 +15683,7 @@ function Gf() {
15683
15683
  return We;
15684
15684
  }
15685
15685
  var An = {}, ra;
15686
- function jf() {
15686
+ function Vf() {
15687
15687
  if (ra) return An;
15688
15688
  ra = 1;
15689
15689
  var r = ut.Buffer;
@@ -15769,7 +15769,7 @@ function jf() {
15769
15769
  return An;
15770
15770
  }
15771
15771
  var Ht = {}, sa;
15772
- function Vf() {
15772
+ function Hf() {
15773
15773
  if (sa) return Ht;
15774
15774
  sa = 1;
15775
15775
  var r = ut.Buffer;
@@ -15865,7 +15865,7 @@ function Vf() {
15865
15865
  }, Ht;
15866
15866
  }
15867
15867
  var kr = {}, ia;
15868
- function Hf() {
15868
+ function Wf() {
15869
15869
  if (ia) return kr;
15870
15870
  ia = 1;
15871
15871
  var r = ut.Buffer;
@@ -15906,7 +15906,7 @@ function Hf() {
15906
15906
  }, kr;
15907
15907
  }
15908
15908
  var aa, oa;
15909
- function Wf() {
15909
+ function $f() {
15910
15910
  return oa || (oa = 1, aa = {
15911
15911
  // Not supported by iconv, not sure why.
15912
15912
  10029: "maccenteuro",
@@ -16055,7 +16055,7 @@ function Wf() {
16055
16055
  }), aa;
16056
16056
  }
16057
16057
  var ca, la;
16058
- function $f() {
16058
+ function qf() {
16059
16059
  return la || (la = 1, ca = {
16060
16060
  437: "cp437",
16061
16061
  737: "cp737",
@@ -16511,7 +16511,7 @@ function $f() {
16511
16511
  }), ca;
16512
16512
  }
16513
16513
  var Lr = {}, ha;
16514
- function qf() {
16514
+ function Xf() {
16515
16515
  if (ha) return Lr;
16516
16516
  ha = 1;
16517
16517
  var r = ut.Buffer;
@@ -16751,7 +16751,7 @@ function qf() {
16751
16751
  }
16752
16752
  return Lr;
16753
16753
  }
16754
- const Xf = [
16754
+ const Yf = [
16755
16755
  [
16756
16756
  "0",
16757
16757
  "\0",
@@ -17296,7 +17296,7 @@ const Xf = [
17296
17296
  "fc40",
17297
17297
  "髜魵魲鮏鮱鮻鰀鵰鵫鶴鸙黑"
17298
17298
  ]
17299
- ], Yf = [
17299
+ ], Zf = [
17300
17300
  [
17301
17301
  "0",
17302
17302
  "\0",
@@ -20994,7 +20994,7 @@ const Xf = [
20994
20994
  "8135f437",
20995
20995
  ""
20996
20996
  ]
20997
- ], Zf = [
20997
+ ], Kf = [
20998
20998
  128,
20999
20999
  165,
21000
21000
  169,
@@ -21202,7 +21202,7 @@ const Xf = [
21202
21202
  65375,
21203
21203
  65510,
21204
21204
  65536
21205
- ], Kf = [
21205
+ ], Qf = [
21206
21206
  0,
21207
21207
  36,
21208
21208
  38,
@@ -21410,10 +21410,10 @@ const Xf = [
21410
21410
  39265,
21411
21411
  39394,
21412
21412
  189e3
21413
- ], Qf = {
21414
- uChars: Zf,
21415
- gbChars: Kf
21416
- }, Jf = [
21413
+ ], Jf = {
21414
+ uChars: Kf,
21415
+ gbChars: Qf
21416
+ }, eg = [
21417
21417
  [
21418
21418
  "0",
21419
21419
  "\0",
@@ -24516,7 +24516,7 @@ const Xf = [
24516
24516
  "f9a1",
24517
24517
  "龤灨灥糷虪蠾蠽蠿讞貜躩軉靋顳顴飌饡馫驤驦驧鬤鸕鸗齈戇欞爧虌躨钂钀钁驩驨鬮鸙爩虋讟钃鱹麷癵驫鱺鸝灩灪麤齾齉龘碁銹裏墻恒粧嫺╔╦╗╠╬╣╚╩╝╒╤╕╞╪╡╘╧╛╓╥╖╟╫╢╙╨╜║═╭╮╰╯▓"
24518
24518
  ]
24519
- ], eg = [
24519
+ ], tg = [
24520
24520
  [
24521
24521
  "8740",
24522
24522
  "䏰䰲䘃䖦䕸𧉧䵷䖳𧲱䳢𧳅㮕䜶䝄䱇䱀𤊿𣘗𧍒𦺋𧃒䱗𪍑䝏䗚䲅𧱬䴇䪤䚡𦬣爥𥩔𡩣𣸆𣽡晍囻"
@@ -25021,7 +25021,7 @@ const Xf = [
25021
25021
  ]
25022
25022
  ];
25023
25023
  var pa, fa;
25024
- function tg() {
25024
+ function ng() {
25025
25025
  return fa || (fa = 1, pa = {
25026
25026
  // == Japanese/ShiftJIS ====================================================
25027
25027
  // All japanese encodings are based on JIS X set of standards:
@@ -25056,7 +25056,7 @@ function tg() {
25056
25056
  shiftjis: {
25057
25057
  type: "_dbcs",
25058
25058
  table: function() {
25059
- return Xf;
25059
+ return Yf;
25060
25060
  },
25061
25061
  encodeAdd: { "¥": 92, "‾": 126 },
25062
25062
  encodeSkipVals: [{ from: 60736, to: 63808 }]
@@ -25074,7 +25074,7 @@ function tg() {
25074
25074
  eucjp: {
25075
25075
  type: "_dbcs",
25076
25076
  table: function() {
25077
- return Yf;
25077
+ return Zf;
25078
25078
  },
25079
25079
  encodeAdd: { "¥": 92, "‾": 126 }
25080
25080
  },
@@ -25121,7 +25121,7 @@ function tg() {
25121
25121
  return Br.concat(ua);
25122
25122
  },
25123
25123
  gb18030: function() {
25124
- return Qf;
25124
+ return Jf;
25125
25125
  },
25126
25126
  encodeSkipVals: [128],
25127
25127
  encodeAdd: { "€": 41699 }
@@ -25135,7 +25135,7 @@ function tg() {
25135
25135
  cp949: {
25136
25136
  type: "_dbcs",
25137
25137
  table: function() {
25138
- return Jf;
25138
+ return eg;
25139
25139
  }
25140
25140
  },
25141
25141
  cseuckr: "cp949",
@@ -25182,7 +25182,7 @@ function tg() {
25182
25182
  big5hkscs: {
25183
25183
  type: "_dbcs",
25184
25184
  table: function() {
25185
- return da.concat(eg);
25185
+ return da.concat(tg);
25186
25186
  },
25187
25187
  encodeSkipVals: [
25188
25188
  // Although Encoding Standard says we should avoid encoding to HKSCS area (See Step 1 of
@@ -25264,10 +25264,9 @@ function tg() {
25264
25264
  }), pa;
25265
25265
  }
25266
25266
  var ga;
25267
- function ng() {
25267
+ function rg() {
25268
25268
  return ga || (ga = 1, function(r) {
25269
25269
  for (var e = Ho, t = [
25270
- zf(),
25271
25270
  Gf(),
25272
25271
  jf(),
25273
25272
  Vf(),
@@ -25275,7 +25274,8 @@ function ng() {
25275
25274
  Wf(),
25276
25275
  $f(),
25277
25276
  qf(),
25278
- tg()
25277
+ Xf(),
25278
+ ng()
25279
25279
  ], n = 0; n < t.length; n++) {
25280
25280
  var s = t[n];
25281
25281
  e(r, s);
@@ -25283,7 +25283,7 @@ function ng() {
25283
25283
  }(Qi)), Qi;
25284
25284
  }
25285
25285
  var Ar, ma;
25286
- function rg() {
25286
+ function sg() {
25287
25287
  if (ma) return Ar;
25288
25288
  ma = 1;
25289
25289
  var r = ut.Buffer;
@@ -25352,10 +25352,10 @@ function rg() {
25352
25352
  };
25353
25353
  }, Ar;
25354
25354
  }
25355
- const sg = {}, ig = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
25355
+ const ig = {}, ag = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
25356
25356
  __proto__: null,
25357
- default: sg
25358
- }, Symbol.toStringTag, { value: "Module" })), ag = /* @__PURE__ */ Ef(ig);
25357
+ default: ig
25358
+ }, Symbol.toStringTag, { value: "Module" })), og = /* @__PURE__ */ Mf(ag);
25359
25359
  (function(r) {
25360
25360
  var e = ut.Buffer, t = Os, n = Ho, s = r.exports;
25361
25361
  s.encodings = null, s.defaultCharUnicode = "�", s.defaultCharSingleByte = "?", s.encode = function(a, o, c) {
@@ -25374,7 +25374,7 @@ const sg = {}, ig = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineP
25374
25374
  }
25375
25375
  }, s.toEncoding = s.encode, s.fromEncoding = s.decode, s._codecDataCache = { __proto__: null }, s.getCodec = function(a) {
25376
25376
  if (!s.encodings) {
25377
- var o = ng();
25377
+ var o = rg();
25378
25378
  s.encodings = { __proto__: null }, n(s.encodings, o);
25379
25379
  }
25380
25380
  for (var c = s._canonicalizeEncoding(a), l = {}; ; ) {
@@ -25407,7 +25407,7 @@ const sg = {}, ig = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineP
25407
25407
  return c.bomAware && !(o && o.stripBOM === !1) && (l = new t.StripBOM(l, o)), l;
25408
25408
  }, s.enableStreamingAPI = function(a) {
25409
25409
  if (!s.supportsStreams) {
25410
- var o = rg()(a);
25410
+ var o = sg()(a);
25411
25411
  s.IconvLiteEncoderStream = o.IconvLiteEncoderStream, s.IconvLiteDecoderStream = o.IconvLiteDecoderStream, s.encodeStream = function(c, l) {
25412
25412
  return new s.IconvLiteEncoderStream(s.getEncoder(c, l), l);
25413
25413
  }, s.decodeStream = function(c, l) {
@@ -25417,15 +25417,15 @@ const sg = {}, ig = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineP
25417
25417
  };
25418
25418
  var i;
25419
25419
  try {
25420
- i = ag;
25420
+ i = og;
25421
25421
  } catch {
25422
25422
  }
25423
25423
  i && i.Transform ? s.enableStreamingAPI(i) : s.encodeStream = s.decodeStream = function() {
25424
25424
  throw new Error("iconv-lite Streaming API is not enabled. Use iconv.enableStreamingAPI(require('stream')); to enable it.");
25425
25425
  };
25426
25426
  })(Go);
25427
- var og = Go.exports;
25428
- const cg = /* @__PURE__ */ If(og);
25427
+ var cg = Go.exports;
25428
+ const lg = /* @__PURE__ */ Ef(cg);
25429
25429
  class Rs extends Va {
25430
25430
  /**
25431
25431
  * Creates a new instance of ShxTextShape
@@ -25433,7 +25433,8 @@ class Rs extends Va {
25433
25433
  * @param shape - The shape data for this character
25434
25434
  */
25435
25435
  constructor(e, t, n, s) {
25436
- super(), this.fontSize = t, this.shape = n, this.font = s, this.code = e, this.width = this.calcWidth();
25436
+ var i;
25437
+ super(), this.fontSize = t, this.shape = n, this.font = s, this.code = e, s.data.header.fontType === me.BIGFONT ? this.width = this.calcWidth() : this.width = ((i = n.lastPoint) == null ? void 0 : i.x) ?? this.calcWidth();
25437
25438
  }
25438
25439
  calcWidth() {
25439
25440
  const e = this.shape.bbox;
@@ -25472,9 +25473,9 @@ class Rs extends Va {
25472
25473
  return e;
25473
25474
  }
25474
25475
  }
25475
- class lg extends ja {
25476
+ class hg extends ja {
25476
25477
  constructor(e) {
25477
- super(e), this.type = "shx", this.font = new Tf(e.data), this.data = this.font.fontData;
25478
+ super(e), this.type = "shx", this.font = new If(e.data), this.data = this.font.fontData;
25478
25479
  }
25479
25480
  /**
25480
25481
  * Return true if this font contains glyph of the specified character. Otherwise, return false.
@@ -25546,7 +25547,7 @@ class lg extends ja {
25546
25547
  * For an unsupported char, use "?" as a replacement.
25547
25548
  */
25548
25549
  getNotFoundTextShape(e) {
25549
- const t = this.font.fontData.header.fontType === be.BIGFONT ? "?" : "?";
25550
+ const t = this.font.fontData.header.fontType === me.BIGFONT ? "?" : "?";
25550
25551
  return this.getCharShape(t, e);
25551
25552
  }
25552
25553
  /**
@@ -25555,8 +25556,8 @@ class lg extends ja {
25555
25556
  * @returns Returns encoded code of the specified character
25556
25557
  */
25557
25558
  getCode(e) {
25558
- if (this.font.fontData.header.fontType === be.BIGFONT && this.encoding) {
25559
- const t = cg.encode(e[0], this.encoding);
25559
+ if (this.font.fontData.header.fontType === me.BIGFONT && this.encoding) {
25560
+ const t = lg.encode(e[0], this.encoding);
25560
25561
  return t.length === 1 ? t[0] : t[0] << 8 | t[1];
25561
25562
  } else
25562
25563
  return e.charCodeAt(0);
@@ -25582,7 +25583,7 @@ let Or = class Yt {
25582
25583
  */
25583
25584
  createFont(e) {
25584
25585
  if (e.type === "shx")
25585
- return new lg(e);
25586
+ return new hg(e);
25586
25587
  if (e.type === "mesh")
25587
25588
  return new yf(e);
25588
25589
  throw new Error("Unsupported font data type");
@@ -25951,11 +25952,12 @@ class Wo {
25951
25952
  }
25952
25953
  }
25953
25954
  var At = /* @__PURE__ */ ((r) => (r[r.NONE = 0] = "NONE", r[r.WORD = 1] = "WORD", r[r.STACK = 2] = "STACK", r[r.SPACE = 3] = "SPACE", r[r.NBSP = 4] = "NBSP", r[r.TABULATOR = 5] = "TABULATOR", r[r.NEW_PARAGRAPH = 6] = "NEW_PARAGRAPH", r[r.NEW_COLUMN = 7] = "NEW_COLUMN", r[r.WRAP_AT_DIMLINE = 8] = "WRAP_AT_DIMLINE", r[r.PROPERTIES_CHANGED = 9] = "PROPERTIES_CHANGED", r))(At || {}), Kt = /* @__PURE__ */ ((r) => (r[r.BOTTOM = 0] = "BOTTOM", r[r.MIDDLE = 1] = "MIDDLE", r[r.TOP = 2] = "TOP", r))(Kt || {}), Ee = /* @__PURE__ */ ((r) => (r[r.DEFAULT = 0] = "DEFAULT", r[r.LEFT = 1] = "LEFT", r[r.RIGHT = 2] = "RIGHT", r[r.CENTER = 3] = "CENTER", r[r.JUSTIFIED = 4] = "JUSTIFIED", r[r.DISTRIBUTED = 5] = "DISTRIBUTED", r))(Ee || {});
25954
- const hg = {
25955
+ const ug = {
25955
25956
  c: "Ø",
25956
25957
  d: "°",
25957
- p: "±"
25958
- }, ug = {
25958
+ p: "±",
25959
+ "%": "%"
25960
+ }, dg = {
25959
25961
  l: 1,
25960
25962
  r: 2,
25961
25963
  c: 3,
@@ -25963,14 +25965,14 @@ const hg = {
25963
25965
  d: 5
25964
25966
  /* DISTRIBUTED */
25965
25967
  };
25966
- function dg(r, e = !1) {
25968
+ function pg(r, e = !1) {
25967
25969
  const t = /* @__PURE__ */ new Set(), n = /\\[fF](.*?)[;|]/g;
25968
25970
  return [...r.matchAll(n)].forEach((s) => {
25969
25971
  let i = s[1].toLowerCase();
25970
25972
  e && (i = i.replace(/\.(ttf|otf|woff|shx)$/, "")), t.add(i);
25971
25973
  }), t;
25972
25974
  }
25973
- class pg {
25975
+ class fg {
25974
25976
  /**
25975
25977
  * Creates a new ContextStack with an initial context.
25976
25978
  * @param initial The initial MTextContext to use as the base of the stack.
@@ -26022,7 +26024,7 @@ class pg {
26022
26024
  this.stack[this.stack.length - 1] = e;
26023
26025
  }
26024
26026
  }
26025
- class fg {
26027
+ class gg {
26026
26028
  /**
26027
26029
  * Creates a new MTextParser instance
26028
26030
  * @param content - The MText content to parse
@@ -26032,7 +26034,7 @@ class fg {
26032
26034
  constructor(e, t, n = {}) {
26033
26035
  this.continueStroke = !1, this.inStackContext = !1, this.scanner = new Pr(e);
26034
26036
  const s = t ?? new vn();
26035
- this.ctxStack = new pg(s), this.yieldPropertyCommands = n.yieldPropertyCommands ?? !1, this.resetParagraphParameters = n.resetParagraphParameters ?? !1, this.mifDecoder = n.mifDecoder ?? this.decodeMultiByteChar.bind(this), this.mifCodeLength = n.mifCodeLength ?? "auto";
26037
+ this.ctxStack = new fg(s), this.yieldPropertyCommands = n.yieldPropertyCommands ?? !1, this.resetParagraphParameters = n.resetParagraphParameters ?? !1, this.mifDecoder = n.mifDecoder ?? this.decodeMultiByteChar.bind(this), this.mifCodeLength = n.mifCodeLength ?? "auto";
26036
26038
  }
26037
26039
  /**
26038
26040
  * Decode multi-byte character from hex code
@@ -26409,7 +26411,7 @@ class fg {
26409
26411
  break;
26410
26412
  case "q": {
26411
26413
  const l = t.get();
26412
- for (a = ug[l] || 0; t.peek() === ","; )
26414
+ for (a = dg[l] || 0; t.peek() === ","; )
26413
26415
  t.consume(1);
26414
26416
  break;
26415
26417
  }
@@ -26546,12 +26548,17 @@ class fg {
26546
26548
  continue;
26547
26549
  }
26548
26550
  if (a === "%" && this.scanner.peek(1) === "%") {
26549
- const c = this.scanner.peek(2).toLowerCase(), l = hg[c];
26551
+ const c = this.scanner.peek(2).toLowerCase(), l = ug[c];
26550
26552
  if (l) {
26551
26553
  this.scanner.consume(3), s += l;
26552
26554
  continue;
26553
26555
  } else {
26554
- this.scanner.consume(3);
26556
+ const h = [c, this.scanner.peek(3), this.scanner.peek(4)];
26557
+ if (h.every((d) => d >= "0" && d <= "9")) {
26558
+ const d = Number.parseInt(h.join(""), 10);
26559
+ this.scanner.consume(5), s += String.fromCharCode(d);
26560
+ } else
26561
+ this.scanner.consume(3);
26555
26562
  continue;
26556
26563
  }
26557
26564
  }
@@ -27002,7 +27009,7 @@ class Dr {
27002
27009
  }
27003
27010
  }
27004
27011
  var un = /* @__PURE__ */ ((r) => (r[r.LEFT_TO_RIGHT = 1] = "LEFT_TO_RIGHT", r[r.RIGHT_TO_LEFT = 2] = "RIGHT_TO_LEFT", r[r.TOP_TO_BOTTOM = 3] = "TOP_TO_BOTTOM", r[r.BOTTOM_TO_TOP = 4] = "BOTTOM_TO_TOP", r[r.BY_STYLE = 5] = "BY_STYLE", r))(un || {});
27005
- const gg = /* @__PURE__ */ new C.Vector3(), mg = 1.666666;
27012
+ const mg = /* @__PURE__ */ new C.Vector3(), yg = 1.666666;
27006
27013
  class Fs extends vn {
27007
27014
  /**
27008
27015
  * Creates a new RenderContext instance with optional initial values.
@@ -27036,7 +27043,7 @@ class Fs extends vn {
27036
27043
  this.color.rgb = [t, n, s];
27037
27044
  }
27038
27045
  }
27039
- class yg {
27046
+ class bg {
27040
27047
  /**
27041
27048
  * Construct one instance of this class and initialize some properties with default values.
27042
27049
  * @param style Input text style
@@ -27135,7 +27142,7 @@ class yg {
27135
27142
  * The height of current line of texts
27136
27143
  */
27137
27144
  get currentLineHeight() {
27138
- return this.defaultLineSpaceFactor * this.currentFontSize * mg + this.currentMaxFontSize;
27145
+ return this.defaultLineSpaceFactor * this.currentFontSize * yg + this.currentMaxFontSize;
27139
27146
  }
27140
27147
  /**
27141
27148
  * The maximum font size in current line. Characters in one line may have different font and font
@@ -27538,7 +27545,7 @@ class yg {
27538
27545
  if (e.forEach((n, s) => {
27539
27546
  n.boundingBox || n.computeBoundingBox(), s === 0 ? t = n.boundingBox : t.union(n.boundingBox);
27540
27547
  }), t) {
27541
- const n = t.getSize(gg);
27548
+ const n = t.getSize(mg);
27542
27549
  switch (this.currentHorizontalAlignment) {
27543
27550
  case Ee.LEFT:
27544
27551
  e.forEach(
@@ -27643,7 +27650,7 @@ class Jn extends C.Object3D {
27643
27650
  * ```
27644
27651
  */
27645
27652
  static getFonts(e, t = !1) {
27646
- return dg(e, t);
27653
+ return pg(e, t);
27647
27654
  }
27648
27655
  /**
27649
27656
  * Creates a new instance of MText.
@@ -27811,12 +27818,12 @@ class Jn extends C.Object3D {
27811
27818
  value: e.widthFactor ?? 1,
27812
27819
  isRelative: !0
27813
27820
  }, h.align = i, h.paragraph.align = s;
27814
- const d = new yg(
27821
+ const d = new bg(
27815
27822
  t,
27816
27823
  this.styleManager,
27817
27824
  this.fontManager,
27818
27825
  l
27819
- ), u = new fg(e.text, h, {
27826
+ ), u = new gg(e.text, h, {
27820
27827
  resetParagraphParameters: !0,
27821
27828
  yieldPropertyCommands: !0
27822
27829
  }).parse();
@@ -27938,7 +27945,7 @@ class $o {
27938
27945
  return e.isByLayer && e.layer ? `layer_${e.layer}_${e.color}` : `entity_${e.color}`;
27939
27946
  }
27940
27947
  }
27941
- class bg {
27948
+ class vg {
27942
27949
  constructor(e = {}) {
27943
27950
  this.workers = [], this.inFlightPerWorker = [], this.pendingRequests = /* @__PURE__ */ new Map(), this.requestId = 0, this.readyPromise = null, this.poolSize = e.poolSize ?? Math.max(
27944
27951
  1,
@@ -28179,7 +28186,7 @@ class bg {
28179
28186
  this.terminate();
28180
28187
  }
28181
28188
  }
28182
- class vg {
28189
+ class xg {
28183
28190
  constructor() {
28184
28191
  this.fontManager = Xe.instance, this.defaultStyleManager = new $o(), this.isInitialized = !1;
28185
28192
  }
@@ -28252,7 +28259,7 @@ class vg {
28252
28259
  this.isInitialized || (await this.loadFonts([Xe.instance.defaultFont]), this.isInitialized = !0);
28253
28260
  }
28254
28261
  }
28255
- class xg {
28262
+ class wg {
28256
28263
  /**
28257
28264
  * Constructor
28258
28265
  *
@@ -28261,7 +28268,7 @@ class xg {
28261
28268
  * when render mode is 'worker'.
28262
28269
  */
28263
28270
  constructor(e = "main", t = {}) {
28264
- this.defaultMode = e, this.mainThreadRenderer = new vg(), this.webWorkerRenderer = new bg(t), this.renderer = this.mainThreadRenderer, e === "worker" && (this.renderer = this.webWorkerRenderer);
28271
+ this.defaultMode = e, this.mainThreadRenderer = new xg(), this.webWorkerRenderer = new vg(t), this.renderer = this.mainThreadRenderer, e === "worker" && (this.renderer = this.webWorkerRenderer);
28265
28272
  }
28266
28273
  /**
28267
28274
  * Sets one new style manager to override the default style manager
@@ -28341,7 +28348,7 @@ var ge;
28341
28348
  (function(r) {
28342
28349
  r[r.BeforeStart = 0] = "BeforeStart", r[r.EqualStart = 1] = "EqualStart", r[r.BetweenStartAndEnd = 2] = "BetweenStartAndEnd", r[r.EqualEnd = 3] = "EqualEnd", r[r.AfterEnd = 4] = "AfterEnd";
28343
28350
  })(ge || (ge = {}));
28344
- class wg {
28351
+ class Sg {
28345
28352
  pointsSame(e, t) {
28346
28353
  return this.pointsSameX(e, t) && this.pointsSameY(e, t);
28347
28354
  }
@@ -28349,7 +28356,7 @@ class wg {
28349
28356
  return this.pointsSameX(e, t) ? this.pointsSameY(e, t) ? 0 : e[1] < t[1] ? -1 : 1 : e[0] < t[0] ? -1 : 1;
28350
28357
  }
28351
28358
  }
28352
- class qo extends wg {
28359
+ class qo extends Sg {
28353
28360
  constructor(e = 1e-10) {
28354
28361
  super(), this.epsilon = e;
28355
28362
  }
@@ -28599,7 +28606,7 @@ class $t {
28599
28606
  return Wt(e, [0, 2, 1, 0, 2, 0, 0, 1, 1, 0, 0, 2, 0, 1, 2, 0], t);
28600
28607
  }
28601
28608
  }
28602
- function Sg(r, e, t) {
28609
+ function _g(r, e, t) {
28603
28610
  const n = [], s = [];
28604
28611
  for (const i of r) {
28605
28612
  let d = function(v, w, S) {
@@ -28665,7 +28672,7 @@ function Sg(r, e, t) {
28665
28672
  }
28666
28673
  return s;
28667
28674
  }
28668
- class _g {
28675
+ class Cg {
28669
28676
  constructor() {
28670
28677
  this.list = [], this.nextSegmentId = 0, this.curVert = NaN;
28671
28678
  }
@@ -28751,7 +28758,7 @@ class Xo {
28751
28758
  }
28752
28759
  buildLog(e) {
28753
28760
  var t;
28754
- return this.log = e ? new _g() : null, (t = this.log) === null || t === void 0 ? void 0 : t.list;
28761
+ return this.log = e ? new Cg() : null, (t = this.log) === null || t === void 0 ? void 0 : t.list;
28755
28762
  }
28756
28763
  segments(e) {
28757
28764
  const t = new wa(!0, this.geo, this.log);
@@ -28806,7 +28813,7 @@ class Xo {
28806
28813
  }
28807
28814
  polygon(e) {
28808
28815
  return {
28809
- regions: Sg(e.segments, this.geo, this.log),
28816
+ regions: _g(e.segments, this.geo, this.log),
28810
28817
  inverted: e.inverted
28811
28818
  };
28812
28819
  }
@@ -28963,7 +28970,7 @@ const De = [
28963
28970
  24,
28964
28971
  24,
28965
28972
  25
28966
- ], Cg = /* @__PURE__ */ new Map([
28973
+ ], Tg = /* @__PURE__ */ new Map([
28967
28974
  [
28968
28975
  2,
28969
28976
  {
@@ -29437,7 +29444,7 @@ class rt {
29437
29444
  }
29438
29445
  initialize() {
29439
29446
  const e = /* @__PURE__ */ new Map();
29440
- return Cg.forEach((t, n) => {
29447
+ return Tg.forEach((t, n) => {
29441
29448
  const s = new C.BufferGeometry();
29442
29449
  s.setAttribute(
29443
29450
  "position",
@@ -29663,7 +29670,7 @@ class ls {
29663
29670
  };
29664
29671
  }
29665
29672
  }
29666
- const Tg = new C.Color(583902);
29673
+ const Ig = new C.Color(583902);
29667
29674
  class er {
29668
29675
  /**
29669
29676
  * Clone given material(s)
@@ -29679,7 +29686,7 @@ class er {
29679
29686
  }
29680
29687
  return e.clone();
29681
29688
  }
29682
- static setMaterialColor(e, t = Tg) {
29689
+ static setMaterialColor(e, t = Ig) {
29683
29690
  if (Array.isArray(e)) {
29684
29691
  e.forEach((n) => this.setMaterialColor(n, t));
29685
29692
  return;
@@ -29721,7 +29728,7 @@ function Nt(r, e) {
29721
29728
  }
29722
29729
  }
29723
29730
  const _a = /* @__PURE__ */ new C.Box3(), _t = /* @__PURE__ */ new C.Vector3(), Ct = /* @__PURE__ */ new C.LineSegments(), Dn = [];
29724
- class Ig extends C.LineSegments {
29731
+ class Eg extends C.LineSegments {
29725
29732
  constructor(e = 1e3, t = e * 2, n) {
29726
29733
  super(new C.BufferGeometry(), n), this.boundingBox = null, this.boundingSphere = null, this._geometryInfo = [], this._availableGeometryIds = [], this._nextIndexStart = 0, this._nextVertexStart = 0, this._geometryCount = 0, this._geometryInitialized = !1, this.frustumCulled = !1, this._maxVertexCount = e, this._maxIndexCount = t;
29727
29734
  }
@@ -30086,7 +30093,7 @@ class Ig extends C.LineSegments {
30086
30093
  }
30087
30094
  }
30088
30095
  const Ca = /* @__PURE__ */ new C.Box3(), Tt = /* @__PURE__ */ new C.Vector3(), It = /* @__PURE__ */ new C.Mesh(), Rn = [];
30089
- class Eg extends C.Mesh {
30096
+ class Mg extends C.Mesh {
30090
30097
  constructor(e = 1e3, t = e * 2, n) {
30091
30098
  super(new C.BufferGeometry(), n), this.boundingBox = null, this.boundingSphere = null, this._geometryInfo = [], this._availableGeometryIds = [], this._nextIndexStart = 0, this._nextVertexStart = 0, this._geometryCount = 0, this._geometryInitialized = !1, this.frustumCulled = !1, this._maxVertexCount = e, this._maxIndexCount = t;
30092
30099
  }
@@ -30421,7 +30428,7 @@ class Eg extends C.Mesh {
30421
30428
  }
30422
30429
  }
30423
30430
  const Ta = /* @__PURE__ */ new C.Box3(), Et = /* @__PURE__ */ new C.Vector3(), Mt = /* @__PURE__ */ new C.Points(), Un = [];
30424
- class Mg extends C.Points {
30431
+ class kg extends C.Points {
30425
30432
  constructor(e = 1e3, t) {
30426
30433
  super(new C.BufferGeometry(), t), this.boundingBox = null, this.boundingSphere = null, this._geometryInfo = [], this._availableGeometryIds = [], this._nextVertexStart = 0, this._geometryCount = 0, this._geometryInitialized = !1, this.frustumCulled = !1, this._maxVertexCount = e;
30427
30434
  }
@@ -30709,7 +30716,7 @@ class Mg extends C.Points {
30709
30716
  return this.geometry.dispose(), this;
30710
30717
  }
30711
30718
  }
30712
- class kg extends C.Group {
30719
+ class Lg extends C.Group {
30713
30720
  constructor() {
30714
30721
  super(), this._pointBatches = /* @__PURE__ */ new Map(), this._pointSymbolBatches = /* @__PURE__ */ new Map(), this._lineBatches = /* @__PURE__ */ new Map(), this._lineWithIndexBatches = /* @__PURE__ */ new Map(), this._meshBatches = /* @__PURE__ */ new Map(), this._meshWithIndexBatches = /* @__PURE__ */ new Map(), this._entitiesMap = /* @__PURE__ */ new Map(), this._selectedObjects = new C.Group(), this._hoverObjects = new C.Group(), this.add(this._selectedObjects), this.add(this._hoverObjects);
30715
30722
  }
@@ -30892,7 +30899,7 @@ class kg extends C.Group {
30892
30899
  addLine(e, t) {
30893
30900
  const n = e.material, s = this.getMatchedLineBatches(e);
30894
30901
  let i = s.get(n.id);
30895
- i == null && (i = new Ig(1e3, 2e3, n), s.set(n.id, i), this.add(i)), e.geometry.applyMatrix4(e.matrixWorld);
30902
+ i == null && (i = new Eg(1e3, 2e3, n), s.set(n.id, i), this.add(i)), e.geometry.applyMatrix4(e.matrixWorld);
30896
30903
  const a = i.addGeometry(e.geometry);
30897
30904
  return i.setGeometryInfo(a, t), {
30898
30905
  batchedObjectId: i.id,
@@ -30902,7 +30909,7 @@ class kg extends C.Group {
30902
30909
  addMesh(e, t) {
30903
30910
  const n = e.material, s = this.getMatchedMeshBatches(e);
30904
30911
  let i = s.get(n.id);
30905
- i == null && (i = new Eg(1e3, 2e3, n), s.set(n.id, i), this.add(i)), e.geometry.applyMatrix4(e.matrixWorld);
30912
+ i == null && (i = new Mg(1e3, 2e3, n), s.set(n.id, i), this.add(i)), e.geometry.applyMatrix4(e.matrixWorld);
30906
30913
  const a = i.addGeometry(e.geometry);
30907
30914
  return i.setGeometryInfo(a, t), {
30908
30915
  batchedObjectId: i.id,
@@ -30912,7 +30919,7 @@ class kg extends C.Group {
30912
30919
  addPoint(e, t) {
30913
30920
  const n = e.material;
30914
30921
  let s = this._pointBatches.get(n.id);
30915
- s == null && (s = new Mg(100, n), s.visible = e.visible, this._pointBatches.set(n.id, s), this.add(s)), e.geometry.applyMatrix4(e.matrixWorld);
30922
+ s == null && (s = new kg(100, n), s.visible = e.visible, this._pointBatches.set(n.id, s), this.add(s)), e.geometry.applyMatrix4(e.matrixWorld);
30916
30923
  const i = s.addGeometry(e.geometry);
30917
30924
  return s.setGeometryInfo(i, t), {
30918
30925
  batchedObjectId: s.id,
@@ -30968,7 +30975,7 @@ class Yo extends C.Object3D {
30968
30975
  return this._styleManager = e._styleManager, super.copy(e, t);
30969
30976
  }
30970
30977
  }
30971
- class ye extends Yo {
30978
+ class be extends Yo {
30972
30979
  constructor(e) {
30973
30980
  super(e), this._box = new C.Box3();
30974
30981
  }
@@ -31064,13 +31071,13 @@ class ye extends Yo {
31064
31071
  * this entity. Preserve transformations.
31065
31072
  */
31066
31073
  flatten() {
31067
- ye.flattenObject(this);
31074
+ be.flattenObject(this);
31068
31075
  }
31069
31076
  /**
31070
31077
  * Remove this object from its parent and release geometry and material resource used by this object.
31071
31078
  */
31072
31079
  dispose() {
31073
- ye.disposeObject(this);
31080
+ be.disposeObject(this);
31074
31081
  }
31075
31082
  async draw() {
31076
31083
  }
@@ -31128,7 +31135,7 @@ class ye extends Yo {
31128
31135
  * @inheritdoc
31129
31136
  */
31130
31137
  fastDeepClone() {
31131
- const e = new ye(this.styleManager);
31138
+ const e = new be(this.styleManager);
31132
31139
  return e.copy(this, !1), this.copyGeometry(this, e), e;
31133
31140
  }
31134
31141
  /**
@@ -31166,11 +31173,11 @@ class ye extends Yo {
31166
31173
  return a;
31167
31174
  }
31168
31175
  }
31169
- class or extends ye {
31176
+ class or extends be {
31170
31177
  constructor(e, t) {
31171
31178
  super(t), e.forEach((i) => {
31172
31179
  if (Array.isArray(i)) {
31173
- const a = new ye(t);
31180
+ const a = new be(t);
31174
31181
  this.add(a), this.box.union(a.box);
31175
31182
  } else
31176
31183
  this.add(i), this.box.union(i.box);
@@ -31237,7 +31244,7 @@ class Ia {
31237
31244
  */
31238
31245
  remove(e) {
31239
31246
  const t = this.entities.get(e);
31240
- t && (this.transientGroup.remove(t), ye.disposeObject(t), this.entities.delete(e));
31247
+ t && (this.transientGroup.remove(t), be.disposeObject(t), this.entities.delete(e));
31241
31248
  }
31242
31249
  /**
31243
31250
  * Retrieve a transient entity by ID.
@@ -31264,7 +31271,7 @@ class Ia {
31264
31271
  this.clear(), this.scene.remove(this.transientGroup);
31265
31272
  }
31266
31273
  }
31267
- let Lg = class {
31274
+ let Bg = class {
31268
31275
  constructor(e) {
31269
31276
  this.unsupportedTextStyles = {}, this._styleManager = e;
31270
31277
  }
@@ -31343,8 +31350,8 @@ const Zo = class Qt {
31343
31350
  * @param workerUrl - URL to the worker script
31344
31351
  */
31345
31352
  initialize(e) {
31346
- if (this._workerUrl = e, this._renderer = new xg("worker", { workerUrl: e }), this._fontUrl && this._renderer.setFontUrl(this._fontUrl), this._renderMode && this._renderer.setDefaultMode(this._renderMode), this._styleManager) {
31347
- const t = new Lg(this._styleManager);
31353
+ if (this._workerUrl = e, this._renderer = new wg("worker", { workerUrl: e }), this._fontUrl && this._renderer.setFontUrl(this._fontUrl), this._renderMode && this._renderer.setDefaultMode(this._renderMode), this._styleManager) {
31354
+ const t = new Bg(this._styleManager);
31348
31355
  this._renderer.setStyleManager(t);
31349
31356
  }
31350
31357
  }
@@ -31360,12 +31367,12 @@ const Zo = class Qt {
31360
31367
  };
31361
31368
  Zo._instance = null;
31362
31369
  let lt = Zo;
31363
- class Bg extends Wo {
31370
+ class Ag extends Wo {
31364
31371
  onFontUrlChanged(e) {
31365
31372
  lt.getInstance().setFontUrl(e);
31366
31373
  }
31367
31374
  }
31368
- class Ag extends ye {
31375
+ class Og extends be {
31369
31376
  constructor(e, t, n) {
31370
31377
  super(n);
31371
31378
  const s = URL.createObjectURL(e), i = new C.TextureLoader().load(s);
@@ -31392,7 +31399,7 @@ class Ag extends ye {
31392
31399
  e.setAttribute("uv", new C.BufferAttribute(n, 2));
31393
31400
  }
31394
31401
  }
31395
- class Og extends ye {
31402
+ class Pg extends be {
31396
31403
  constructor(e, t, n) {
31397
31404
  super(n);
31398
31405
  const s = this.styleManager.getLineMaterial(t), i = e.length, a = new Float32Array(i * 3), o = i * 2 > 65535 ? new Uint32Array(i * 2) : new Uint16Array(i * 2);
@@ -31411,7 +31418,7 @@ class Og extends ye {
31411
31418
  e.computeBoundingBox(), this.box = e.boundingBox;
31412
31419
  }
31413
31420
  }
31414
- class Pg extends ye {
31421
+ class Dg extends be {
31415
31422
  constructor(e, t, n, s, i) {
31416
31423
  super(i);
31417
31424
  const a = this.styleManager.getLineMaterial(s), o = new C.BufferGeometry();
@@ -31423,7 +31430,7 @@ class Pg extends ye {
31423
31430
  dn.computeLineDistances(c), this.add(c);
31424
31431
  }
31425
31432
  }
31426
- class Dg extends ye {
31433
+ class Rg extends be {
31427
31434
  constructor(e, t, n, s, i = !1) {
31428
31435
  super(s), this._text = e, this._style = {
31429
31436
  ...n,
@@ -31481,8 +31488,8 @@ class Dg extends ye {
31481
31488
  (n = this._mtext) == null || n.raycast(e, t);
31482
31489
  }
31483
31490
  }
31484
- const Rg = /* @__PURE__ */ new C.Vector3();
31485
- class Ug extends ye {
31491
+ const Ug = /* @__PURE__ */ new C.Vector3();
31492
+ class Fg extends be {
31486
31493
  constructor(e, t, n, s) {
31487
31494
  super(s);
31488
31495
  const i = rt.instance.create(
@@ -31490,7 +31497,7 @@ class Ug extends ye {
31490
31497
  e
31491
31498
  );
31492
31499
  this.isShowPoint = i.point != null;
31493
- const a = i.point ?? new C.BufferGeometry().setFromPoints([Rg.copy(e)]);
31500
+ const a = i.point ?? new C.BufferGeometry().setFromPoints([Ug.copy(e)]);
31494
31501
  a.computeBoundingBox(), a.boundingBox && this.box.union(a.boundingBox);
31495
31502
  const o = this.styleManager.getPointsMaterial(t), c = new C.Points(a, o);
31496
31503
  if (c.userData.bboxIntersectionCheck = !0, c.visible = this.isShowPoint, this.add(c), i.line) {
@@ -31501,7 +31508,7 @@ class Ug extends ye {
31501
31508
  }
31502
31509
  }
31503
31510
  }
31504
- class Fg extends ye {
31511
+ class Ng extends be {
31505
31512
  constructor(e, t, n) {
31506
31513
  var s;
31507
31514
  super(n);
@@ -31619,7 +31626,7 @@ class Fg extends ye {
31619
31626
  return s;
31620
31627
  }
31621
31628
  }
31622
- function Ng(r, e, t, n, s = 0) {
31629
+ function zg(r, e, t, n, s = 0) {
31623
31630
  const i = {
31624
31631
  u_cameraZoom: { value: t },
31625
31632
  u_patternLines: { value: r },
@@ -31904,7 +31911,7 @@ class Gs {
31904
31911
  return e.color.isByLayer || e.lineType.type === "ByLayer";
31905
31912
  }
31906
31913
  }
31907
- class zg extends Gs {
31914
+ class Gg extends Gs {
31908
31915
  /**
31909
31916
  * Create either MeshBasicMaterial or hatch shader material
31910
31917
  */
@@ -31972,7 +31979,7 @@ class zg extends Gs {
31972
31979
  }
31973
31980
  c.push(T);
31974
31981
  }
31975
- const h = Ng(
31982
+ const h = zg(
31976
31983
  c,
31977
31984
  n.patternAngle,
31978
31985
  this.options.cameraZoomUniform,
@@ -31998,7 +32005,7 @@ class zg extends Gs {
31998
32005
  return `hatch_${e.layer}_${e.rgbColor}_${n.patternAngle}_${s}`;
31999
32006
  }
32000
32007
  }
32001
- class Gg {
32008
+ class jg {
32002
32009
  /**
32003
32010
  * Creates line shader by given pattern.
32004
32011
  * Note: remember to call line.computeLineDistances() in order to make it work!
@@ -32089,7 +32096,7 @@ class Gg {
32089
32096
  });
32090
32097
  }
32091
32098
  }
32092
- class jg extends Gs {
32099
+ class Vg extends Gs {
32093
32100
  /**
32094
32101
  * Builds a stable material key from traits.
32095
32102
  * Key differs for shader vs basic, ByLayer vs ByEntity.
@@ -32104,7 +32111,7 @@ class jg extends Gs {
32104
32111
  }
32105
32112
  createMaterialImpl(e, t = {}) {
32106
32113
  let n;
32107
- return this.isShaderMaterial(e, t) ? n = Gg.createLineShaderMaterial(
32114
+ return this.isShaderMaterial(e, t) ? n = jg.createLineShaderMaterial(
32108
32115
  e.lineType.pattern,
32109
32116
  e.rgbColor,
32110
32117
  e.lineTypeScale,
@@ -32113,7 +32120,7 @@ class jg extends Gs {
32113
32120
  ) : n = new C.LineBasicMaterial({ color: e.rgbColor }), n;
32114
32121
  }
32115
32122
  }
32116
- class Vg extends Gs {
32123
+ class Hg extends Gs {
32117
32124
  /**
32118
32125
  * Builds a stable material key from traits.
32119
32126
  */
@@ -32134,7 +32141,7 @@ class Vg extends Gs {
32134
32141
  }
32135
32142
  const Ko = class Vn {
32136
32143
  constructor() {
32137
- this.unsupportedTextStyles = {}, this.pointMgr = new Vg(Vn.options), this.lineMgr = new jg(Vn.options), this.fillMgr = new zg(Vn.options);
32144
+ this.unsupportedTextStyles = {}, this.pointMgr = new Hg(Vn.options), this.lineMgr = new Vg(Vn.options), this.fillMgr = new Gg(Vn.options);
32138
32145
  }
32139
32146
  /**
32140
32147
  * Returns a material for point entities.
@@ -32161,7 +32168,7 @@ const Ko = class Vn {
32161
32168
  * @param traits - Current entity traits.
32162
32169
  * @param rebaseOffset - Offset used to transform pattern origins.
32163
32170
  */
32164
- getFillMaterial(e, t = Wg) {
32171
+ getFillMaterial(e, t = $g) {
32165
32172
  return this.fillMgr.getMaterial(e, {
32166
32173
  rebaseOffset: t
32167
32174
  });
@@ -32193,13 +32200,13 @@ Ko.options = {
32193
32200
  viewportScaleUniform: 1,
32194
32201
  maxFragmentUniforms: 1024
32195
32202
  };
32196
- let Hg = Ko;
32197
- const Wg = /* @__PURE__ */ new C.Vector2(0, 0);
32198
- class $g {
32203
+ let Wg = Ko;
32204
+ const $g = /* @__PURE__ */ new C.Vector2(0, 0);
32205
+ class qg {
32199
32206
  constructor(e) {
32200
32207
  this.events = {
32201
- fontNotFound: new me()
32202
- }, this._renderer = e, this._styleManager = new Hg(), lt.getInstance().overrideStyleManager(this._styleManager), Xe.instance.events.fontNotFound.addEventListener((t) => {
32208
+ fontNotFound: new ye()
32209
+ }, this._renderer = e, this._styleManager = new Wg(), lt.getInstance().overrideStyleManager(this._styleManager), Xe.instance.events.fontNotFound.addEventListener((t) => {
32203
32210
  this.events.fontNotFound.dispatch(t);
32204
32211
  }), this._subEntityTraits = ls.createDefaultTraits();
32205
32212
  }
@@ -32313,7 +32320,7 @@ class $g {
32313
32320
  * Create one empty entity
32314
32321
  */
32315
32322
  createEntity() {
32316
- return new ye(this._styleManager);
32323
+ return new be(this._styleManager);
32317
32324
  }
32318
32325
  /**
32319
32326
  * @inheritdoc
@@ -32325,7 +32332,7 @@ class $g {
32325
32332
  * @inheritdoc
32326
32333
  */
32327
32334
  point(e, t) {
32328
- return new Ug(
32335
+ return new Fg(
32329
32336
  e,
32330
32337
  this._subEntityTraits,
32331
32338
  t,
@@ -32354,7 +32361,7 @@ class $g {
32354
32361
  * @inheritdoc
32355
32362
  */
32356
32363
  lineSegments(e, t, n) {
32357
- return new Pg(
32364
+ return new Dg(
32358
32365
  e,
32359
32366
  t,
32360
32367
  n,
@@ -32366,13 +32373,13 @@ class $g {
32366
32373
  * @inheritdoc
32367
32374
  */
32368
32375
  area(e) {
32369
- return new Fg(e, this._subEntityTraits, this._styleManager);
32376
+ return new Ng(e, this._subEntityTraits, this._styleManager);
32370
32377
  }
32371
32378
  /**
32372
32379
  * @inheritdoc
32373
32380
  */
32374
32381
  mtext(e, t, n) {
32375
- return new Dg(
32382
+ return new Rg(
32376
32383
  e,
32377
32384
  this._subEntityTraits,
32378
32385
  t,
@@ -32384,7 +32391,7 @@ class $g {
32384
32391
  * @inheritdoc
32385
32392
  */
32386
32393
  image(e, t) {
32387
- return new Ag(e, t, this._styleManager);
32394
+ return new Og(e, t, this._styleManager);
32388
32395
  }
32389
32396
  /**
32390
32397
  * Clears all cached materials and releases its memory
@@ -32393,10 +32400,10 @@ class $g {
32393
32400
  this._styleManager.dispose(), Xe.instance.missedFonts = {};
32394
32401
  }
32395
32402
  linePoints(e) {
32396
- return new Og(e, this._subEntityTraits, this._styleManager);
32403
+ return new Pg(e, this._subEntityTraits, this._styleManager);
32397
32404
  }
32398
32405
  }
32399
- class qg {
32406
+ class Xg {
32400
32407
  constructor(e) {
32401
32408
  this._camera = e;
32402
32409
  }
@@ -32505,10 +32512,10 @@ class Qo {
32505
32512
  */
32506
32513
  constructor(e, t, n) {
32507
32514
  this._frustum = 400, this.events = {
32508
- viewChanged: new me()
32515
+ viewChanged: new ye()
32509
32516
  }, this._renderer = e, this._width = t, this._height = n;
32510
32517
  const s = this.createCamera();
32511
- this._camera = new qg(s), this._cameraControls = this.createCameraControls(), this._cameraControls.addEventListener("change", () => {
32518
+ this._camera = new Xg(s), this._cameraControls = this.createCameraControls(), this._cameraControls.addEventListener("change", () => {
32512
32519
  this.events.viewChanged.dispatch({ view: this });
32513
32520
  }), this._raycaster = new C.Raycaster();
32514
32521
  }
@@ -32696,7 +32703,7 @@ class tr extends Qo {
32696
32703
  }
32697
32704
  }
32698
32705
  }
32699
- class Xg extends vs {
32706
+ class Yg extends vs {
32700
32707
  /**
32701
32708
  * Creates a circle jig.
32702
32709
  *
@@ -32712,14 +32719,14 @@ class Xg extends vs {
32712
32719
  this._circle.radius = e;
32713
32720
  }
32714
32721
  }
32715
- class Yg extends ve {
32722
+ class Zg extends ve {
32716
32723
  async execute(e) {
32717
32724
  const t = new st(
32718
32725
  ce.t("jig.circle.center")
32719
32726
  ), n = await ee.instance.editor.getPoint(t), s = new ml(
32720
32727
  ce.t("jig.circle.radius")
32721
32728
  );
32722
- s.jig = new Xg(e.view, n);
32729
+ s.jig = new Yg(e.view, n);
32723
32730
  const i = await ee.instance.editor.getDistance(s), a = e.doc.database, o = new ps(n, i);
32724
32731
  a.tables.blockTable.modelSpace.appendEntity(o);
32725
32732
  }
@@ -32834,7 +32841,7 @@ class cr {
32834
32841
  return this;
32835
32842
  }
32836
32843
  }
32837
- class Zg extends cr {
32844
+ class Kg extends cr {
32838
32845
  constructor(e) {
32839
32846
  if (super(), e.closed)
32840
32847
  this.svg = `
@@ -32848,7 +32855,7 @@ class Zg extends cr {
32848
32855
  this._box.min.copy(t.min), this._box.max.copy(t.max);
32849
32856
  }
32850
32857
  }
32851
- class Kg extends cr {
32858
+ class Qg extends cr {
32852
32859
  constructor(e) {
32853
32860
  if (super(), e.closed)
32854
32861
  this.svg = `
@@ -32864,7 +32871,7 @@ class Kg extends cr {
32864
32871
  this._box.min.copy(t.min), this._box.max.copy(t.max);
32865
32872
  }
32866
32873
  }
32867
- class Qg extends cr {
32874
+ class Jg extends cr {
32868
32875
  constructor(e) {
32869
32876
  super();
32870
32877
  const t = e.reduce(
@@ -32874,7 +32881,7 @@ class Qg extends cr {
32874
32881
  t && (this.svg = `<path d="${t}" />`);
32875
32882
  }
32876
32883
  }
32877
- class Jg {
32884
+ class em {
32878
32885
  constructor() {
32879
32886
  this._container = new Array(), this._bbox = new Ke(), this._subEntityTraits = {
32880
32887
  color: new $n(),
@@ -32934,21 +32941,21 @@ class Jg {
32934
32941
  * @inheritdoc
32935
32942
  */
32936
32943
  circularArc(e) {
32937
- const t = new Zg(e);
32944
+ const t = new Kg(e);
32938
32945
  return this._container.push(t.svg), this._bbox.union(t.box), t;
32939
32946
  }
32940
32947
  /**
32941
32948
  * @inheritdoc
32942
32949
  */
32943
32950
  ellipticalArc(e) {
32944
- const t = new Kg(e);
32951
+ const t = new Qg(e);
32945
32952
  return this._container.push(t.svg), this._bbox.union(t.box), t;
32946
32953
  }
32947
32954
  /**
32948
32955
  * @inheritdoc
32949
32956
  */
32950
32957
  lines(e) {
32951
- const t = new Qg(e);
32958
+ const t = new Jg(e);
32952
32959
  return this._container.push(t.svg), this._bbox.union(t.box), t;
32953
32960
  }
32954
32961
  /**
@@ -33003,7 +33010,7 @@ class Jg {
33003
33010
  }
33004
33011
  }
33005
33012
  const kt = /* @__PURE__ */ new cr();
33006
- class em {
33013
+ class tm {
33007
33014
  /**
33008
33015
  * Converts the current CAD drawing to SVG format and initiates download.
33009
33016
  *
@@ -33020,7 +33027,7 @@ class em {
33020
33027
  * ```
33021
33028
  */
33022
33029
  convert() {
33023
- const e = ee.instance.curDocument.database.tables.blockTable.modelSpace.newIterator(), t = new Jg();
33030
+ const e = ee.instance.curDocument.database.tables.blockTable.modelSpace.newIterator(), t = new em();
33024
33031
  for (const n of e)
33025
33032
  n.worldDraw(t);
33026
33033
  this.createFileAndDownloadIt(t.export());
@@ -33044,7 +33051,7 @@ class em {
33044
33051
  s.href = n, s.download = "example.svg", document.body.appendChild(s), s.click();
33045
33052
  }
33046
33053
  }
33047
- class tm extends ve {
33054
+ class nm extends ve {
33048
33055
  /**
33049
33056
  * Executes the SVG conversion command.
33050
33057
  *
@@ -33054,10 +33061,10 @@ class tm extends ve {
33054
33061
  * @param _context - The application context (unused in this command)
33055
33062
  */
33056
33063
  execute(e) {
33057
- new em().convert();
33064
+ new tm().convert();
33058
33065
  }
33059
33066
  }
33060
- class nm extends vs {
33067
+ class rm extends vs {
33061
33068
  /**
33062
33069
  * Creates a dimension jig.
33063
33070
  *
@@ -33085,7 +33092,7 @@ class nm extends vs {
33085
33092
  return Math.atan2(s, n);
33086
33093
  }
33087
33094
  }
33088
- class rm extends ve {
33095
+ class sm extends ve {
33089
33096
  async execute(e) {
33090
33097
  const t = new st(
33091
33098
  ce.t("jig.dimlinear.xLine1Point")
@@ -33096,7 +33103,7 @@ class rm extends ve {
33096
33103
  const i = await ee.instance.editor.getPoint(s), a = new st(
33097
33104
  ce.t("jig.dimlinear.dimLinePoint")
33098
33105
  );
33099
- a.jig = new nm(
33106
+ a.jig = new rm(
33100
33107
  e.view,
33101
33108
  e.doc.database,
33102
33109
  n,
@@ -33121,7 +33128,7 @@ class rm extends ve {
33121
33128
  return `*D${n + 1}`;
33122
33129
  }
33123
33130
  }
33124
- class sm extends vs {
33131
+ class im extends vs {
33125
33132
  /**
33126
33133
  * Creates a line jig.
33127
33134
  *
@@ -33137,19 +33144,19 @@ class sm extends vs {
33137
33144
  this._line.endPoint = e;
33138
33145
  }
33139
33146
  }
33140
- class im extends ve {
33147
+ class am extends ve {
33141
33148
  async execute(e) {
33142
33149
  const t = new st(
33143
33150
  ce.t("jig.line.firstPoint")
33144
33151
  ), n = await ee.instance.editor.getPoint(t), s = new st(
33145
33152
  ce.t("jig.line.nextPoint")
33146
33153
  );
33147
- s.useDashedLine = !0, s.jig = new sm(e.view, n), s.useDashedLine = !0, s.useBasePoint = !0;
33154
+ s.useDashedLine = !0, s.jig = new im(e.view, n), s.useDashedLine = !0, s.useBasePoint = !0;
33148
33155
  const i = await ee.instance.editor.getPoint(s), a = e.doc.database, o = new gs(n, i);
33149
33156
  a.tables.blockTable.modelSpace.appendEntity(o);
33150
33157
  }
33151
33158
  }
33152
- class am extends ve {
33159
+ class om extends ve {
33153
33160
  execute(e) {
33154
33161
  this.printSelectionSet(e), this.printStats(e), this.printPerformanceData();
33155
33162
  }
@@ -33197,7 +33204,7 @@ class am extends ve {
33197
33204
  cc.getInstance().printAll();
33198
33205
  }
33199
33206
  }
33200
- class om extends ve {
33207
+ class cm extends ve {
33201
33208
  /**
33202
33209
  * Executes the open file command.
33203
33210
  *
@@ -33211,7 +33218,7 @@ class om extends ve {
33211
33218
  ot.emit("open-file", {});
33212
33219
  }
33213
33220
  }
33214
- class cm extends ve {
33221
+ class lm extends ve {
33215
33222
  /**
33216
33223
  * Executes the quick new command.
33217
33224
  *
@@ -33225,7 +33232,7 @@ class cm extends ve {
33225
33232
  ee.instance.openUrl(t + "templates/acadiso.dxf");
33226
33233
  }
33227
33234
  }
33228
- class lm extends ve {
33235
+ class hm extends ve {
33229
33236
  /**
33230
33237
  * Executes the regen command to redraw the current drawing
33231
33238
  */
@@ -33233,7 +33240,7 @@ class lm extends ve {
33233
33240
  ee.instance.regen();
33234
33241
  }
33235
33242
  }
33236
- class hm extends ve {
33243
+ class um extends ve {
33237
33244
  /**
33238
33245
  * Executes the select command.
33239
33246
  *
@@ -33246,7 +33253,7 @@ class hm extends ve {
33246
33253
  e.view.mode = it.SELECTION, e.view.setCursor(pn.Crosshair);
33247
33254
  }
33248
33255
  }
33249
- class um extends ve {
33256
+ class dm extends ve {
33250
33257
  /**
33251
33258
  * Executes the command to modify the value of one system variable.
33252
33259
  *
@@ -33257,7 +33264,7 @@ class um extends ve {
33257
33264
  s.getDescriptor(this.globalName) && s.setVar(this.globalName, n);
33258
33265
  }
33259
33266
  }
33260
- class dm extends ve {
33267
+ class pm extends ve {
33261
33268
  /**
33262
33269
  * Executes the zoom to fit command.
33263
33270
  *
@@ -33270,7 +33277,7 @@ class dm extends ve {
33270
33277
  e.view.zoomToFitDrawing();
33271
33278
  }
33272
33279
  }
33273
- class pm extends ve {
33280
+ class fm extends ve {
33274
33281
  /**
33275
33282
  * Executes the zoom-to-box command.
33276
33283
  *
@@ -33285,7 +33292,7 @@ class pm extends ve {
33285
33292
  return e.view.zoomTo(t, 1);
33286
33293
  }
33287
33294
  }
33288
- class fm extends ve {
33295
+ class gm extends ve {
33289
33296
  /**
33290
33297
  * Executes the pan command.
33291
33298
  *
@@ -33298,36 +33305,36 @@ class fm extends ve {
33298
33305
  e.view.mode = it.PAN, e.view.setCursor(pn.Grab);
33299
33306
  }
33300
33307
  }
33301
- const gm = (r) => new Oa(r.min, r.max), mm = (r) => new Ke(
33308
+ const mm = (r) => new Oa(r.min, r.max), ym = (r) => new Ke(
33302
33309
  r.min,
33303
33310
  r.max
33304
- ), ym = (r) => new C.Box3(
33311
+ ), bm = (r) => new C.Box3(
33305
33312
  r.min,
33306
33313
  r.max
33307
- ), bm = (r) => new Ke(r.min, r.max), vm = (r) => new C.Box2(
33314
+ ), vm = (r) => new Ke(r.min, r.max), xm = (r) => new C.Box2(
33308
33315
  r.min,
33309
33316
  r.max
33310
- ), xm = (r) => new Ke(r.min, r.max), wm = (r) => {
33317
+ ), wm = (r) => new Ke(r.min, r.max), Sm = (r) => {
33311
33318
  const e = new C.Box3();
33312
33319
  return e.min.set(r.min.x, r.min.y, 0), e.max.set(r.max.x, r.max.y, 0), e;
33313
33320
  }, Ea = {
33314
33321
  /** Converts Three.js Box2 to CAD geometry AcGeBox2d */
33315
- threeBo2dToGeBox2d: bm,
33322
+ threeBo2dToGeBox2d: vm,
33316
33323
  /** Converts CAD geometry AcGeBox2d to Three.js Box2 */
33317
- geBox2dToThreeBox2d: vm,
33324
+ geBox2dToThreeBox2d: xm,
33318
33325
  /** Converts Three.js Box3 to CAD geometry AcGeBox3d */
33319
- threeBox3dToGeBox3d: gm,
33326
+ threeBox3dToGeBox3d: mm,
33320
33327
  /** Converts CAD geometry AcGeBox3d to Three.js Box3 */
33321
- geBox3dToThreeBox3d: ym,
33328
+ geBox3dToThreeBox3d: bm,
33322
33329
  /** Converts CAD geometry AcGeBox3d to CAD geometry AcGeBox2d */
33323
- goBox3dToGeBox2d: mm,
33330
+ goBox3dToGeBox2d: ym,
33324
33331
  /** Converts Three.js Box3 to CAD geometry Box2d (ignores Z) */
33325
- threeBox3dToGeBox2d: xm,
33332
+ threeBox3dToGeBox2d: wm,
33326
33333
  /** Converts CAD geometry AcGeBox2d to Three.js Box3 (Z=0) */
33327
- geBox2dToThreeBox3d: wm
33334
+ geBox2dToThreeBox3d: Sm
33328
33335
  };
33329
33336
  var lr = /* @__PURE__ */ ((r) => (r[r.LEFT_BOTTOM = 0] = "LEFT_BOTTOM", r[r.LEFT_TOP = 1] = "LEFT_TOP", r[r.RIGHT_TOP = 2] = "RIGHT_TOP", r[r.RIGHT_BOTTOM = 4] = "RIGHT_BOTTOM", r))(lr || {});
33330
- class Sm extends C.Object3D {
33337
+ class _m extends C.Object3D {
33331
33338
  /**
33332
33339
  * Construct one instance of this gizmo
33333
33340
  * @param camera Camera used in your canvas
@@ -33411,7 +33418,7 @@ class Sm extends C.Object3D {
33411
33418
  return a;
33412
33419
  }
33413
33420
  }
33414
- function _m(r, e) {
33421
+ function Cm(r, e) {
33415
33422
  const t = e.font || "Helvetica", n = e.fontSize || 30, s = e.width || 200, i = e.height || 200, a = e.bgColor ? e.bgColor.join(", ") : "255, 255, 255, 1.0", o = e.color ? e.color.join(", ") : "0, 0, 0, 1.0", c = document.createElement("canvas");
33416
33423
  c.width = s, c.height = i;
33417
33424
  const l = c.getContext("2d");
@@ -33428,7 +33435,7 @@ function _m(r, e) {
33428
33435
  return h.minFilter = C.LinearFilter, h.needsUpdate = !0, h;
33429
33436
  }
33430
33437
  function zr(r) {
33431
- const e = _m(r, {
33438
+ const e = Cm(r, {
33432
33439
  fontSize: 100,
33433
33440
  font: "Arial Narrow, sans-serif",
33434
33441
  color: [255, 255, 255, 1],
@@ -33437,15 +33444,15 @@ function zr(r) {
33437
33444
  return new C.Sprite(t);
33438
33445
  }
33439
33446
  lr.RIGHT_TOP;
33440
- const Cm = {
33447
+ const Tm = {
33441
33448
  pos: lr.LEFT_BOTTOM,
33442
33449
  size: 100,
33443
33450
  hasZAxis: !0
33444
33451
  };
33445
- class Tm extends Sm {
33452
+ class Im extends _m {
33446
33453
  constructor(e, t, n) {
33447
33454
  const s = {
33448
- ...Cm,
33455
+ ...Tm,
33449
33456
  ...n
33450
33457
  };
33451
33458
  super(e, t, s.size, n.pos), this.hasZAxis = s.hasZAxis;
@@ -33487,7 +33494,7 @@ class Tm extends Sm {
33487
33494
  this.axes.geometry.dispose(), this.axes.material.dispose(), this.xText.geometry.dispose(), this.xText.material.dispose(), this.yText.geometry.dispose(), this.yText.material.dispose(), this.hasZAxis && ((e = this.zText) == null || e.geometry.dispose(), (t = this.zText) == null || t.material.dispose());
33488
33495
  }
33489
33496
  }
33490
- class Im extends Qo {
33497
+ class Em extends Qo {
33491
33498
  /**
33492
33499
  * Construct one instance of this class.
33493
33500
  *
@@ -33578,7 +33585,7 @@ class Im extends Qo {
33578
33585
  * @returns The configured axes gizmo instance
33579
33586
  */
33580
33587
  createAxesGizmo() {
33581
- return new Tm(
33588
+ return new Im(
33582
33589
  this._camera.internalCamera,
33583
33590
  this._renderer.internalRenderer,
33584
33591
  {
@@ -33612,7 +33619,7 @@ class Im extends Qo {
33612
33619
  }
33613
33620
  }
33614
33621
  }
33615
- class Em {
33622
+ class Mm {
33616
33623
  /**
33617
33624
  * Creates a new layout view manager instance.
33618
33625
  * Initializes with no active layout and an empty collection of views.
@@ -33695,7 +33702,7 @@ class Em {
33695
33702
  (t = this.activeLayoutView) == null || t.render(e);
33696
33703
  }
33697
33704
  }
33698
- function Jo(r, e, t = 0, n = r.length - 1, s = Mm) {
33705
+ function Jo(r, e, t = 0, n = r.length - 1, s = km) {
33699
33706
  for (; n > t; ) {
33700
33707
  if (n - t > 600) {
33701
33708
  const c = n - t + 1, l = e - t + 1, h = Math.log(c), d = 0.5 * Math.exp(2 * h / 3), u = 0.5 * Math.sqrt(h * d * (c - d) / c) * (l - c / 2 < 0 ? -1 : 1), f = Math.max(t, Math.floor(e - l * d / c + u)), y = Math.min(n, Math.floor(e + (c - l) * d / c + u));
@@ -33714,10 +33721,10 @@ function Xt(r, e, t) {
33714
33721
  const n = r[e];
33715
33722
  r[e] = r[t], r[t] = n;
33716
33723
  }
33717
- function Mm(r, e) {
33724
+ function km(r, e) {
33718
33725
  return r < e ? -1 : r > e ? 1 : 0;
33719
33726
  }
33720
- class km {
33727
+ class Lm {
33721
33728
  constructor(e = 9) {
33722
33729
  this._maxEntries = Math.max(4, e), this._minEntries = Math.max(2, Math.ceil(this._maxEntries * 0.4)), this.clear();
33723
33730
  }
@@ -33788,7 +33795,7 @@ class km {
33788
33795
  let o, c, l;
33789
33796
  for (; n || i.length; ) {
33790
33797
  if (n || (n = i.pop(), c = i[i.length - 1], o = a.pop(), l = !0), n.leaf) {
33791
- const h = Lm(e, n.children, t);
33798
+ const h = Bm(e, n.children, t);
33792
33799
  if (h !== -1)
33793
33800
  return n.children.splice(h, 1), i.push(n), this._condense(i), this;
33794
33801
  }
@@ -33839,7 +33846,7 @@ class km {
33839
33846
  for (; s.push(t), !(t.leaf || s.length - 1 === n); ) {
33840
33847
  let i = 1 / 0, a = 1 / 0, o;
33841
33848
  for (let c = 0; c < t.children.length; c++) {
33842
- const l = t.children[c], h = Gr(l), d = Om(e, l) - h;
33849
+ const l = t.children[c], h = Gr(l), d = Pm(e, l) - h;
33843
33850
  d < a ? (a = d, i = h < i ? h : i, o = l) : d === a && h < i && (i = h, o = l);
33844
33851
  }
33845
33852
  t = o || t.children[0];
@@ -33865,14 +33872,14 @@ class km {
33865
33872
  _chooseSplitIndex(e, t, n) {
33866
33873
  let s, i = 1 / 0, a = 1 / 0;
33867
33874
  for (let o = t; o <= n - t; o++) {
33868
- const c = Jt(e, 0, o, this.toBBox), l = Jt(e, o, n, this.toBBox), h = Pm(c, l), d = Gr(c) + Gr(l);
33875
+ const c = Jt(e, 0, o, this.toBBox), l = Jt(e, o, n, this.toBBox), h = Dm(c, l), d = Gr(c) + Gr(l);
33869
33876
  h < i ? (i = h, s = o, a = d < a ? d : a) : h === i && d < a && (a = d, s = o);
33870
33877
  }
33871
33878
  return s || n - t;
33872
33879
  }
33873
33880
  // sorts node children by the best axis for split
33874
33881
  _chooseSplitAxis(e, t, n) {
33875
- const s = e.leaf ? this.compareMinX : Bm, i = e.leaf ? this.compareMinY : Am, a = this._allDistMargin(e, t, n, s), o = this._allDistMargin(e, t, n, i);
33882
+ const s = e.leaf ? this.compareMinX : Am, i = e.leaf ? this.compareMinY : Om, a = this._allDistMargin(e, t, n, s), o = this._allDistMargin(e, t, n, i);
33876
33883
  a < o && e.children.sort(s);
33877
33884
  }
33878
33885
  // total margin of all possible split distributions where each node is at least m full
@@ -33899,7 +33906,7 @@ class km {
33899
33906
  e[t].children.length === 0 ? t > 0 ? (n = e[t - 1].children, n.splice(n.indexOf(e[t]), 1)) : this.clear() : Lt(e[t], this.toBBox);
33900
33907
  }
33901
33908
  }
33902
- function Lm(r, e, t) {
33909
+ function Bm(r, e, t) {
33903
33910
  if (!t) return e.indexOf(r);
33904
33911
  for (let n = 0; n < e.length; n++)
33905
33912
  if (t(r, e[n])) return n;
@@ -33919,10 +33926,10 @@ function Jt(r, e, t, n, s) {
33919
33926
  function en(r, e) {
33920
33927
  return r.minX = Math.min(r.minX, e.minX), r.minY = Math.min(r.minY, e.minY), r.maxX = Math.max(r.maxX, e.maxX), r.maxY = Math.max(r.maxY, e.maxY), r;
33921
33928
  }
33922
- function Bm(r, e) {
33929
+ function Am(r, e) {
33923
33930
  return r.minX - e.minX;
33924
33931
  }
33925
- function Am(r, e) {
33932
+ function Om(r, e) {
33926
33933
  return r.minY - e.minY;
33927
33934
  }
33928
33935
  function Gr(r) {
@@ -33931,10 +33938,10 @@ function Gr(r) {
33931
33938
  function Fn(r) {
33932
33939
  return r.maxX - r.minX + (r.maxY - r.minY);
33933
33940
  }
33934
- function Om(r, e) {
33941
+ function Pm(r, e) {
33935
33942
  return (Math.max(e.maxX, r.maxX) - Math.min(e.minX, r.minX)) * (Math.max(e.maxY, r.maxY) - Math.min(e.minY, r.minY));
33936
33943
  }
33937
- function Pm(r, e) {
33944
+ function Dm(r, e) {
33938
33945
  const t = Math.max(r.minX, e.minX), n = Math.max(r.minY, e.minY), s = Math.min(r.maxX, e.maxX), i = Math.min(r.maxY, e.maxY);
33939
33946
  return Math.max(0, s - t) * Math.max(0, i - n);
33940
33947
  }
@@ -33963,13 +33970,13 @@ function Ma(r, e, t, n, s) {
33963
33970
  Jo(r, a, e, t, s), i.push(e, a, a, t);
33964
33971
  }
33965
33972
  }
33966
- class Dm {
33973
+ class Rm {
33967
33974
  /**
33968
33975
  * Construct one instance of this class
33969
33976
  * @param layer - Layer information
33970
33977
  */
33971
33978
  constructor(e) {
33972
- this._group = new kg(), this._name = e.name, this._box = new C.Box3(), this._group.visible = !(e.isFrozen || e.isOff);
33979
+ this._group = new Lg(), this._name = e.name, this._box = new C.Box3(), this._group.visible = !(e.isFrozen || e.isOff);
33973
33980
  }
33974
33981
  /**
33975
33982
  * Layer name
@@ -34112,13 +34119,13 @@ class Dm {
34112
34119
  });
34113
34120
  }
34114
34121
  }
34115
- class Rm {
34122
+ class Um {
34116
34123
  /**
34117
34124
  * Creates a new layout instance.
34118
34125
  * Initializes the layout with empty collections and a spatial index.
34119
34126
  */
34120
34127
  constructor() {
34121
- this._group = new C.Group(), this._indexTree = new km(), this._box = new C.Box3(), this._layers = /* @__PURE__ */ new Map();
34128
+ this._group = new C.Group(), this._indexTree = new Lm(), this._box = new C.Box3(), this._layers = /* @__PURE__ */ new Map();
34122
34129
  }
34123
34130
  /**
34124
34131
  * The internal THREE.js object to use by scene. This is internally used only. Try to avoid using it.
@@ -34215,8 +34222,12 @@ class Rm {
34215
34222
  * @returns True if the object intersects with the ray, false otherwise
34216
34223
  */
34217
34224
  isIntersectWith(e, t) {
34218
- const n = this.getLayerByObjectId(e);
34219
- return n && n.isIntersectWith(e, t);
34225
+ const n = this.getLayersByObjectId(e);
34226
+ for (let s = 0; s < n.length; ++s) {
34227
+ const i = n[s];
34228
+ if (i && i.isIntersectWith(e, t)) return !0;
34229
+ }
34230
+ return !1;
34220
34231
  }
34221
34232
  /**
34222
34233
  * Add one AutoCAD entity into this layout. If layer group referenced by the entity doesn't exist, create one
@@ -34287,7 +34298,7 @@ class Rm {
34287
34298
  addLayer(e) {
34288
34299
  const t = e.name;
34289
34300
  let n = this._layers.get(t);
34290
- return n === void 0 && (n = new Dm(e), this._layers.set(t, n), this._group.add(n.internalObject)), n;
34301
+ return n === void 0 && (n = new Rm(e), this._layers.set(t, n), this._group.add(n.internalObject)), n;
34291
34302
  }
34292
34303
  /**
34293
34304
  * Updates layer information (such as visibility). If the layer doesn't exist, do nothing.
@@ -34306,8 +34317,7 @@ class Rm {
34306
34317
  */
34307
34318
  hover(e) {
34308
34319
  e.forEach((t) => {
34309
- const n = this.getLayerByObjectId(t);
34310
- n && n.hover([t]);
34320
+ this.getLayersByObjectId(t).forEach((s) => s.hover([t]));
34311
34321
  });
34312
34322
  }
34313
34323
  /**
@@ -34318,8 +34328,7 @@ class Rm {
34318
34328
  */
34319
34329
  unhover(e) {
34320
34330
  e.forEach((t) => {
34321
- const n = this.getLayerByObjectId(t);
34322
- n && n.unhover([t]);
34331
+ this.getLayersByObjectId(t).forEach((s) => s.unhover([t]));
34323
34332
  });
34324
34333
  }
34325
34334
  /**
@@ -34330,8 +34339,7 @@ class Rm {
34330
34339
  */
34331
34340
  select(e) {
34332
34341
  e.forEach((t) => {
34333
- const n = this.getLayerByObjectId(t);
34334
- n && n.select([t]);
34342
+ this.getLayersByObjectId(t).forEach((s) => s.unselect([t]));
34335
34343
  });
34336
34344
  }
34337
34345
  /**
@@ -34342,8 +34350,7 @@ class Rm {
34342
34350
  */
34343
34351
  unselect(e) {
34344
34352
  e.forEach((t) => {
34345
- const n = this.getLayerByObjectId(t);
34346
- n && n.unselect([t]);
34353
+ this.getLayersByObjectId(t).forEach((s) => s.unselect([t]));
34347
34354
  });
34348
34355
  }
34349
34356
  /**
@@ -34371,17 +34378,28 @@ class Rm {
34371
34378
  });
34372
34379
  }
34373
34380
  /**
34374
- * Finds the layer containing the entity with the specified object ID.
34381
+ * Returns all layers that contain renderable entities associated with
34382
+ * the specified AutoCAD object ID.
34375
34383
  *
34376
- * @param objectId - The object ID to search for
34377
- * @returns The layer containing the entity, or undefined if not found
34384
+ * In AutoCAD, an INSERT entity may reference multiple child entities that
34385
+ * reside on different layers. During rendering, this engine groups entities
34386
+ * by layer and assigns each group the INSERT entity's object ID.
34387
+ *
34388
+ * As a result, a single object ID (typically from an INSERT entity) may
34389
+ * correspond to multiple layers, and this method returns all such layers.
34390
+ *
34391
+ * @param objectId - The AutoCAD object ID to search for (e.g. an INSERT entity ID)
34392
+ * @returns An array of layers containing entities associated with the given object ID;
34393
+ * returns an empty array if no matching layers are found
34378
34394
  */
34379
- getLayerByObjectId(e) {
34380
- for (const [t, n] of this._layers)
34381
- if (n.hasEntity(e)) return n;
34395
+ getLayersByObjectId(e) {
34396
+ const t = [];
34397
+ for (const [n, s] of this._layers)
34398
+ s.hasEntity(e) && t.push(s);
34399
+ return t;
34382
34400
  }
34383
34401
  }
34384
- class Um {
34402
+ class Fm {
34385
34403
  /**
34386
34404
  * Creates a new CAD scene instance.
34387
34405
  *
@@ -34467,7 +34485,7 @@ class Um {
34467
34485
  * @returns Return the newly created empty layout
34468
34486
  */
34469
34487
  addEmptyLayout(e) {
34470
- const t = new Rm();
34488
+ const t = new Um();
34471
34489
  return this._layouts.set(e, t), this._scene.add(t.internalObject), t.visible = e == this._activeLayoutBtrId, this._layers.forEach((n) => {
34472
34490
  t.addLayer(n);
34473
34491
  }), t;
@@ -34589,7 +34607,7 @@ class Um {
34589
34607
  const ka = {
34590
34608
  background: 0
34591
34609
  };
34592
- class Fm extends _l {
34610
+ class Nm extends _l {
34593
34611
  /**
34594
34612
  * Creates a new 2D CAD viewer instance.
34595
34613
  *
@@ -34607,7 +34625,7 @@ class Fm extends _l {
34607
34625
  alpha: !0,
34608
34626
  canvas: e.canvas
34609
34627
  });
34610
- t.canvas == null && (t.canvas = n.domElement), super(t.canvas), e.calculateSizeCallback && this.setCalculateSizeCallback(e.calculateSizeCallback), n.setPixelRatio(Math.min(window.devicePixelRatio, 2)), n.setSize(this.width, this.height), this._renderer = new $g(n);
34628
+ t.canvas == null && (t.canvas = n.domElement), super(t.canvas), e.calculateSizeCallback && this.setCalculateSizeCallback(e.calculateSizeCallback), n.setPixelRatio(Math.min(window.devicePixelRatio, 2)), n.setSize(this.width, this.height), this._renderer = new qg(n);
34611
34629
  const s = Ze.instance.fontMapping;
34612
34630
  this._renderer.setFontMapping(s), this._renderer.events.fontNotFound.addEventListener((i) => {
34613
34631
  ot.emit("font-not-found", {
@@ -34624,7 +34642,7 @@ class Fm extends _l {
34624
34642
  (i) => {
34625
34643
  this.activeLayoutBtrId = i.layout.blockTableRecordId;
34626
34644
  }
34627
- ), this._missedImages = /* @__PURE__ */ new Map(), this._layoutViewManager = new Em(), this.initialize(), this.onWindowResize(), this.animate(), this._isDirty = !0, this._numOfEntitiesToProcess = 0;
34645
+ ), this._missedImages = /* @__PURE__ */ new Map(), this._layoutViewManager = new Mm(), this.initialize(), this.onWindowResize(), this.animate(), this._isDirty = !0, this._numOfEntitiesToProcess = 0;
34628
34646
  }
34629
34647
  /**
34630
34648
  * Initializes the viewer after renderer and camera are created.
@@ -34959,7 +34977,7 @@ class Fm extends _l {
34959
34977
  this._isDirty = this._scene.unhover([e]);
34960
34978
  }
34961
34979
  createScene() {
34962
- const e = new Um();
34980
+ const e = new Fm();
34963
34981
  return e.layouts.forEach((t) => {
34964
34982
  t.setSnapObject(this.renderer.createObject());
34965
34983
  }), e;
@@ -34979,7 +34997,7 @@ class Fm extends _l {
34979
34997
  */
34980
34998
  createLayoutViewIfNeeded(e) {
34981
34999
  let t = this._layoutViewManager.getAt(e);
34982
- return t == null && (t = new Im(
35000
+ return t == null && (t = new Em(
34983
35001
  this._renderer,
34984
35002
  e,
34985
35003
  this.width,
@@ -35049,7 +35067,7 @@ class Fm extends _l {
35049
35067
  c.parent = null;
35050
35068
  const s = e.styleManager, i = e.objectId, a = e.layerName, o = e.box;
35051
35069
  n.forEach((c, l) => {
35052
- const h = new ye(s);
35070
+ const h = new be(s);
35053
35071
  h.applyMatrix4(e.matrix), h.objectId = i, h.ownerId = e.ownerId, h.layerName = l === "0" ? a : l, h.box = o;
35054
35072
  for (let d = 0; d < c.length; d++)
35055
35073
  h.add(c[d]);
@@ -35062,14 +35080,14 @@ class Fm extends _l {
35062
35080
  ));
35063
35081
  }
35064
35082
  }
35065
- class Nm {
35083
+ class zm {
35066
35084
  /**
35067
35085
  * Creates a new font loader instance.
35068
35086
  *
35069
35087
  * @param renderer - The Three.js renderer that will use the loaded fonts
35070
35088
  */
35071
35089
  constructor() {
35072
- this._loader = new Bg();
35090
+ this._loader = new Ag();
35073
35091
  }
35074
35092
  /**
35075
35093
  * Base URL to load fonts
@@ -35442,7 +35460,7 @@ class La {
35442
35460
  }
35443
35461
  }
35444
35462
  }
35445
- class zm extends lc {
35463
+ class Gm extends lc {
35446
35464
  constructor(e = {}) {
35447
35465
  super(e), e.useWorker = !0, e.parserWorkerUrl || (e.parserWorkerUrl = "/assets/libredwg-parser-worker.js");
35448
35466
  }
@@ -35721,7 +35739,7 @@ class zm extends lc {
35721
35739
  return n.flatMap((s) => t[s]);
35722
35740
  }
35723
35741
  }
35724
- function Gm() {
35742
+ function jm() {
35725
35743
  try {
35726
35744
  const r = new Vc({
35727
35745
  convertByEntityType: !1,
@@ -35733,7 +35751,7 @@ function Gm() {
35733
35751
  console.error("Failed to register dxf converter: ", r);
35734
35752
  }
35735
35753
  try {
35736
- const r = new zm({
35754
+ const r = new Gm({
35737
35755
  convertByEntityType: !1,
35738
35756
  useWorker: !0,
35739
35757
  parserWorkerUrl: "./assets/libredwg-parser-worker.js"
@@ -35743,8 +35761,8 @@ function Gm() {
35743
35761
  console.error("Failed to register dwg converter: ", r);
35744
35762
  }
35745
35763
  }
35746
- function jm() {
35747
- Gm(), typeof window < "u" && !!window.location && (window.location.hostname === "localhost" || window.location.hostname === "127.0.0.1") ? lt.getInstance().initialize(
35764
+ function Vm() {
35765
+ jm(), typeof window < "u" && !!window.location && (window.location.hostname === "localhost" || window.location.hostname === "127.0.0.1") ? lt.getInstance().initialize(
35748
35766
  "/assets/mtext-renderer-worker.js"
35749
35767
  ) : lt.getInstance().initialize("./mtext-renderer-worker.js");
35750
35768
  }
@@ -35867,7 +35885,7 @@ const $e = class $e {
35867
35885
  };
35868
35886
  $e.styleId = "ml-ccl-loader-styles", $e.stylesInjected = !1;
35869
35887
  let hs = $e;
35870
- const Vm = {
35888
+ const Hm = {
35871
35889
  isDebug: !1,
35872
35890
  isShowCommandLine: !0,
35873
35891
  isShowCoordinate: !0,
@@ -35882,7 +35900,7 @@ class Ze {
35882
35900
  constructor() {
35883
35901
  this.events = {
35884
35902
  /** Fired when any setting is modified */
35885
- modified: new me()
35903
+ modified: new ye()
35886
35904
  };
35887
35905
  }
35888
35906
  /**
@@ -36116,10 +36134,10 @@ class Ze {
36116
36134
  */
36117
36135
  get settings() {
36118
36136
  const e = localStorage.getItem(Ba), t = e == null ? {} : JSON.parse(e);
36119
- return Zc(t, Vm);
36137
+ return Zc(t, Hm);
36120
36138
  }
36121
36139
  }
36122
- const Hm = "https://mlightcad.gitlab.io/cad-data/";
36140
+ const Wm = "https://mlightcad.gitlab.io/cad-data/";
36123
36141
  class ee {
36124
36142
  /**
36125
36143
  * Private constructor for singleton pattern.
@@ -36133,10 +36151,10 @@ class ee {
36133
36151
  constructor(e = {}) {
36134
36152
  this.events = {
36135
36153
  /** Fired when a new document is created */
36136
- documentCreated: new me(),
36154
+ documentCreated: new ye(),
36137
36155
  /** Fired when a document becomes active */
36138
- documentActivated: new me()
36139
- }, this._baseUrl = e.baseUrl ?? Hm, e.useMainThreadDraw ? lt.getInstance().setRenderMode("main") : lt.getInstance().setRenderMode("worker");
36156
+ documentActivated: new ye()
36157
+ }, this._baseUrl = e.baseUrl ?? Wm, e.useMainThreadDraw ? lt.getInstance().setRenderMode("main") : lt.getInstance().setRenderMode("worker");
36140
36158
  const t = new Cl();
36141
36159
  t.database.events.openProgress.addEventListener((i) => {
36142
36160
  const a = {
@@ -36152,11 +36170,11 @@ class ee {
36152
36170
  const n = () => ({
36153
36171
  width: window.innerWidth,
36154
36172
  height: window.innerHeight - 30
36155
- }), s = new Fm({
36173
+ }), s = new Nm({
36156
36174
  canvas: e.canvas,
36157
36175
  calculateSizeCallback: n
36158
36176
  });
36159
- this._context = new Kc(s, t), this._fontLoader = new Nm(), this._fontLoader.baseUrl = this._baseUrl + "fonts/", ds().workingDatabase = t.database, this.registerCommands(), this._progress = new hs(), this._progress.hide(), e.notLoadDefaultFonts || this.loadDefaultFonts(), jm(), this.createCommandLine();
36177
+ this._context = new Kc(s, t), this._fontLoader = new zm(), this._fontLoader.baseUrl = this._baseUrl + "fonts/", ds().workingDatabase = t.database, this.registerCommands(), this._progress = new hs(), this._progress.hide(), e.notLoadDefaultFonts || this.loadDefaultFonts(), Vm(), this.createCommandLine();
36160
36178
  }
36161
36179
  /**
36162
36180
  * Creates the singleton instance with an optional canvas element.
@@ -36365,68 +36383,68 @@ class ee {
36365
36383
  Q.SYSTEMT_COMMAND_GROUP_NAME,
36366
36384
  "circle",
36367
36385
  "circle",
36368
- new Yg()
36386
+ new Zg()
36369
36387
  ), e.addCommand(
36370
36388
  Q.SYSTEMT_COMMAND_GROUP_NAME,
36371
36389
  "csvg",
36372
36390
  "csvg",
36373
- new tm()
36391
+ new nm()
36374
36392
  ), e.addCommand(
36375
36393
  Q.SYSTEMT_COMMAND_GROUP_NAME,
36376
36394
  "dimlinear",
36377
36395
  "dimlinear",
36378
- new rm()
36396
+ new sm()
36379
36397
  ), e.addCommand(
36380
36398
  Q.SYSTEMT_COMMAND_GROUP_NAME,
36381
36399
  "line",
36382
36400
  "line",
36383
- new im()
36401
+ new am()
36384
36402
  ), e.addCommand(
36385
36403
  Q.SYSTEMT_COMMAND_GROUP_NAME,
36386
36404
  "log",
36387
36405
  "log",
36388
- new am()
36406
+ new om()
36389
36407
  ), e.addCommand(
36390
36408
  Q.SYSTEMT_COMMAND_GROUP_NAME,
36391
36409
  "open",
36392
36410
  "open",
36393
- new om()
36411
+ new cm()
36394
36412
  ), e.addCommand(
36395
36413
  Q.SYSTEMT_COMMAND_GROUP_NAME,
36396
36414
  "pan",
36397
36415
  "pan",
36398
- new fm()
36416
+ new gm()
36399
36417
  ), e.addCommand(
36400
36418
  Q.SYSTEMT_COMMAND_GROUP_NAME,
36401
36419
  "qnew",
36402
36420
  "qnew",
36403
- new cm()
36421
+ new lm()
36404
36422
  ), e.addCommand(
36405
36423
  Q.SYSTEMT_COMMAND_GROUP_NAME,
36406
36424
  "regen",
36407
36425
  "regen",
36408
- new lm()
36426
+ new hm()
36409
36427
  ), e.addCommand(
36410
36428
  Q.SYSTEMT_COMMAND_GROUP_NAME,
36411
36429
  "select",
36412
36430
  "select",
36413
- new hm()
36431
+ new um()
36414
36432
  ), e.addCommand(
36415
36433
  Q.SYSTEMT_COMMAND_GROUP_NAME,
36416
36434
  "zoom",
36417
36435
  "zoom",
36418
- new dm()
36436
+ new pm()
36419
36437
  ), e.addCommand(
36420
36438
  Q.SYSTEMT_COMMAND_GROUP_NAME,
36421
36439
  "zoomw",
36422
36440
  "zoomw",
36423
- new pm()
36441
+ new fm()
36424
36442
  ), us.instance().getAllDescriptors().forEach((n) => {
36425
36443
  e.addCommand(
36426
36444
  Q.SYSTEMT_COMMAND_GROUP_NAME,
36427
36445
  n.name,
36428
36446
  n.name,
36429
- new um()
36447
+ new dm()
36430
36448
  );
36431
36449
  });
36432
36450
  }
@@ -36525,27 +36543,27 @@ class ee {
36525
36543
  }
36526
36544
  }
36527
36545
  export {
36528
- Yg as AcApCircleCmd,
36529
- Xg as AcApCircleJig,
36546
+ Zg as AcApCircleCmd,
36547
+ Yg as AcApCircleJig,
36530
36548
  Kc as AcApContext,
36531
- tm as AcApConvertToSvgCmd,
36532
- nm as AcApDimJig,
36533
- rm as AcApDimLinearCmd,
36549
+ nm as AcApConvertToSvgCmd,
36550
+ rm as AcApDimJig,
36551
+ sm as AcApDimLinearCmd,
36534
36552
  ee as AcApDocManager,
36535
36553
  Cl as AcApDocument,
36536
36554
  ce as AcApI18n,
36537
- im as AcApLineCmd,
36538
- sm as AcApLineJig,
36539
- am as AcApLogCmd,
36540
- om as AcApOpenCmd,
36541
- fm as AcApPanCmd,
36542
- cm as AcApQNewCmd,
36543
- lm as AcApRegenCmd,
36544
- hm as AcApSelectCmd,
36555
+ am as AcApLineCmd,
36556
+ im as AcApLineJig,
36557
+ om as AcApLogCmd,
36558
+ cm as AcApOpenCmd,
36559
+ gm as AcApPanCmd,
36560
+ lm as AcApQNewCmd,
36561
+ hm as AcApRegenCmd,
36562
+ um as AcApSelectCmd,
36545
36563
  Ze as AcApSettingManager,
36546
- um as AcApSysVarCmd,
36547
- dm as AcApZoomCmd,
36548
- pm as AcApZoomToBoxCmd,
36564
+ dm as AcApSysVarCmd,
36565
+ pm as AcApZoomCmd,
36566
+ fm as AcApZoomToBoxCmd,
36549
36567
  _l as AcEdBaseView,
36550
36568
  ve as AcEdCommand,
36551
36569
  cl as AcEdCommandLine,
@@ -36559,10 +36577,10 @@ export {
36559
36577
  bs as AcEdMarker,
36560
36578
  bl as AcEdMarkerManager,
36561
36579
  vs as AcEdPreviewJig,
36562
- e0 as AcEdPromptAngleOptions,
36580
+ t0 as AcEdPromptAngleOptions,
36563
36581
  ml as AcEdPromptDistanceOptions,
36564
- t0 as AcEdPromptDoubleOptions,
36565
- n0 as AcEdPromptIntegerOptions,
36582
+ n0 as AcEdPromptDoubleOptions,
36583
+ r0 as AcEdPromptIntegerOptions,
36566
36584
  ys as AcEdPromptNumericalOptions,
36567
36585
  nr as AcEdPromptOptions,
36568
36586
  st as AcEdPromptPointOptions,
@@ -36570,11 +36588,11 @@ export {
36570
36588
  Sl as AcEdSelectionSet,
36571
36589
  it as AcEdViewMode,
36572
36590
  wl as AcEditor,
36573
- Fm as AcTrView2d,
36591
+ Nm as AcTrView2d,
36574
36592
  ka as DEFAULT_VIEW_2D_OPTIONS,
36575
- Km as acedAlert,
36593
+ Qm as acedAlert,
36576
36594
  Ga as cmdDescription,
36577
36595
  ot as eventBus,
36578
- Qm as sysCmdDescription,
36579
- Jm as userCmdDescription
36596
+ Jm as sysCmdDescription,
36597
+ e0 as userCmdDescription
36580
36598
  };