sysml-diagram 0.10.17 → 0.11.0

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/out/main.js CHANGED
@@ -738,22 +738,22 @@ var require_linkedMap = __commonJS({
738
738
  }
739
739
  forEach(callbackfn, thisArg) {
740
740
  const state = this._state;
741
- let current = this._head;
742
- while (current) {
741
+ let current2 = this._head;
742
+ while (current2) {
743
743
  if (thisArg) {
744
- callbackfn.bind(thisArg)(current.value, current.key, this);
744
+ callbackfn.bind(thisArg)(current2.value, current2.key, this);
745
745
  } else {
746
- callbackfn(current.value, current.key, this);
746
+ callbackfn(current2.value, current2.key, this);
747
747
  }
748
748
  if (this._state !== state) {
749
749
  throw new Error(`LinkedMap got modified during iteration.`);
750
750
  }
751
- current = current.next;
751
+ current2 = current2.next;
752
752
  }
753
753
  }
754
754
  keys() {
755
755
  const state = this._state;
756
- let current = this._head;
756
+ let current2 = this._head;
757
757
  const iterator = {
758
758
  [Symbol.iterator]: () => {
759
759
  return iterator;
@@ -762,9 +762,9 @@ var require_linkedMap = __commonJS({
762
762
  if (this._state !== state) {
763
763
  throw new Error(`LinkedMap got modified during iteration.`);
764
764
  }
765
- if (current) {
766
- const result = { value: current.key, done: false };
767
- current = current.next;
765
+ if (current2) {
766
+ const result = { value: current2.key, done: false };
767
+ current2 = current2.next;
768
768
  return result;
769
769
  } else {
770
770
  return { value: void 0, done: true };
@@ -775,7 +775,7 @@ var require_linkedMap = __commonJS({
775
775
  }
776
776
  values() {
777
777
  const state = this._state;
778
- let current = this._head;
778
+ let current2 = this._head;
779
779
  const iterator = {
780
780
  [Symbol.iterator]: () => {
781
781
  return iterator;
@@ -784,9 +784,9 @@ var require_linkedMap = __commonJS({
784
784
  if (this._state !== state) {
785
785
  throw new Error(`LinkedMap got modified during iteration.`);
786
786
  }
787
- if (current) {
788
- const result = { value: current.value, done: false };
789
- current = current.next;
787
+ if (current2) {
788
+ const result = { value: current2.value, done: false };
789
+ current2 = current2.next;
790
790
  return result;
791
791
  } else {
792
792
  return { value: void 0, done: true };
@@ -797,7 +797,7 @@ var require_linkedMap = __commonJS({
797
797
  }
798
798
  entries() {
799
799
  const state = this._state;
800
- let current = this._head;
800
+ let current2 = this._head;
801
801
  const iterator = {
802
802
  [Symbol.iterator]: () => {
803
803
  return iterator;
@@ -806,9 +806,9 @@ var require_linkedMap = __commonJS({
806
806
  if (this._state !== state) {
807
807
  throw new Error(`LinkedMap got modified during iteration.`);
808
808
  }
809
- if (current) {
810
- const result = { value: [current.key, current.value], done: false };
811
- current = current.next;
809
+ if (current2) {
810
+ const result = { value: [current2.key, current2.value], done: false };
811
+ current2 = current2.next;
812
812
  return result;
813
813
  } else {
814
814
  return { value: void 0, done: true };
@@ -828,17 +828,17 @@ var require_linkedMap = __commonJS({
828
828
  this.clear();
829
829
  return;
830
830
  }
831
- let current = this._head;
831
+ let current2 = this._head;
832
832
  let currentSize = this.size;
833
- while (current && currentSize > newSize) {
834
- this._map.delete(current.key);
835
- current = current.next;
833
+ while (current2 && currentSize > newSize) {
834
+ this._map.delete(current2.key);
835
+ current2 = current2.next;
836
836
  currentSize--;
837
837
  }
838
- this._head = current;
838
+ this._head = current2;
839
839
  this._size = currentSize;
840
- if (current) {
841
- current.previous = void 0;
840
+ if (current2) {
841
+ current2.previous = void 0;
842
842
  }
843
843
  this._state++;
844
844
  }
@@ -3119,7 +3119,7 @@ var require_main = __commonJS({
3119
3119
  exports2.createMessageConnection = exports2.createServerSocketTransport = exports2.createClientSocketTransport = exports2.createServerPipeTransport = exports2.createClientPipeTransport = exports2.generateRandomPipeName = exports2.StreamMessageWriter = exports2.StreamMessageReader = exports2.SocketMessageWriter = exports2.SocketMessageReader = exports2.PortMessageWriter = exports2.PortMessageReader = exports2.IPCMessageWriter = exports2.IPCMessageReader = void 0;
3120
3120
  var ril_1 = require_ril();
3121
3121
  ril_1.default.install();
3122
- var path12 = __require("path");
3122
+ var path10 = __require("path");
3123
3123
  var os2 = __require("os");
3124
3124
  var crypto_1 = __require("crypto");
3125
3125
  var net_1 = __require("net");
@@ -3255,9 +3255,9 @@ var require_main = __commonJS({
3255
3255
  }
3256
3256
  let result;
3257
3257
  if (XDG_RUNTIME_DIR) {
3258
- result = path12.join(XDG_RUNTIME_DIR, `vscode-ipc-${randomSuffix}.sock`);
3258
+ result = path10.join(XDG_RUNTIME_DIR, `vscode-ipc-${randomSuffix}.sock`);
3259
3259
  } else {
3260
- result = path12.join(os2.tmpdir(), `vscode-${randomSuffix}.sock`);
3260
+ result = path10.join(os2.tmpdir(), `vscode-${randomSuffix}.sock`);
3261
3261
  }
3262
3262
  const limit = safeIpcPathLengths.get(process.platform);
3263
3263
  if (limit !== void 0 && result.length > limit) {
@@ -8347,8 +8347,8 @@ var require_files = __commonJS({
8347
8347
  Object.defineProperty(exports2, "__esModule", { value: true });
8348
8348
  exports2.resolveModulePath = exports2.FileSystem = exports2.resolveGlobalYarnPath = exports2.resolveGlobalNodePath = exports2.resolve = exports2.uriToFilePath = void 0;
8349
8349
  var url = __require("url");
8350
- var path12 = __require("path");
8351
- var fs11 = __require("fs");
8350
+ var path10 = __require("path");
8351
+ var fs9 = __require("fs");
8352
8352
  var child_process_1 = __require("child_process");
8353
8353
  function uriToFilePath(uri) {
8354
8354
  let parsed = url.parse(uri);
@@ -8366,7 +8366,7 @@ var require_files = __commonJS({
8366
8366
  segments.shift();
8367
8367
  }
8368
8368
  }
8369
- return path12.normalize(segments.join("/"));
8369
+ return path10.normalize(segments.join("/"));
8370
8370
  }
8371
8371
  exports2.uriToFilePath = uriToFilePath;
8372
8372
  function isWindows() {
@@ -8395,9 +8395,9 @@ var require_files = __commonJS({
8395
8395
  let env = process.env;
8396
8396
  let newEnv = /* @__PURE__ */ Object.create(null);
8397
8397
  Object.keys(env).forEach((key) => newEnv[key] = env[key]);
8398
- if (nodePath && fs11.existsSync(nodePath)) {
8398
+ if (nodePath && fs9.existsSync(nodePath)) {
8399
8399
  if (newEnv[nodePathKey]) {
8400
- newEnv[nodePathKey] = nodePath + path12.delimiter + newEnv[nodePathKey];
8400
+ newEnv[nodePathKey] = nodePath + path10.delimiter + newEnv[nodePathKey];
8401
8401
  } else {
8402
8402
  newEnv[nodePathKey] = nodePath;
8403
8403
  }
@@ -8470,9 +8470,9 @@ var require_files = __commonJS({
8470
8470
  }
8471
8471
  if (prefix.length > 0) {
8472
8472
  if (isWindows()) {
8473
- return path12.join(prefix, "node_modules");
8473
+ return path10.join(prefix, "node_modules");
8474
8474
  } else {
8475
- return path12.join(prefix, "lib", "node_modules");
8475
+ return path10.join(prefix, "lib", "node_modules");
8476
8476
  }
8477
8477
  }
8478
8478
  return void 0;
@@ -8512,7 +8512,7 @@ var require_files = __commonJS({
8512
8512
  try {
8513
8513
  let yarn = JSON.parse(line);
8514
8514
  if (yarn.type === "log") {
8515
- return path12.join(yarn.data, "node_modules");
8515
+ return path10.join(yarn.data, "node_modules");
8516
8516
  }
8517
8517
  } catch (e) {
8518
8518
  }
@@ -8535,24 +8535,24 @@ var require_files = __commonJS({
8535
8535
  if (process.platform === "win32") {
8536
8536
  _isCaseSensitive = false;
8537
8537
  } else {
8538
- _isCaseSensitive = !fs11.existsSync(__filename.toUpperCase()) || !fs11.existsSync(__filename.toLowerCase());
8538
+ _isCaseSensitive = !fs9.existsSync(__filename.toUpperCase()) || !fs9.existsSync(__filename.toLowerCase());
8539
8539
  }
8540
8540
  return _isCaseSensitive;
8541
8541
  }
8542
8542
  FileSystem2.isCaseSensitive = isCaseSensitive;
8543
8543
  function isParent(parent, child) {
8544
8544
  if (isCaseSensitive()) {
8545
- return path12.normalize(child).indexOf(path12.normalize(parent)) === 0;
8545
+ return path10.normalize(child).indexOf(path10.normalize(parent)) === 0;
8546
8546
  } else {
8547
- return path12.normalize(child).toLowerCase().indexOf(path12.normalize(parent).toLowerCase()) === 0;
8547
+ return path10.normalize(child).toLowerCase().indexOf(path10.normalize(parent).toLowerCase()) === 0;
8548
8548
  }
8549
8549
  }
8550
8550
  FileSystem2.isParent = isParent;
8551
8551
  })(FileSystem || (exports2.FileSystem = FileSystem = {}));
8552
8552
  function resolveModulePath(workspaceRoot, moduleName, nodePath, tracer) {
8553
8553
  if (nodePath) {
8554
- if (!path12.isAbsolute(nodePath)) {
8555
- nodePath = path12.join(workspaceRoot, nodePath);
8554
+ if (!path10.isAbsolute(nodePath)) {
8555
+ nodePath = path10.join(workspaceRoot, nodePath);
8556
8556
  }
8557
8557
  return resolve8(moduleName, nodePath, nodePath, tracer).then((value) => {
8558
8558
  if (FileSystem.isParent(nodePath, value)) {
@@ -26068,7 +26068,7 @@ var require_elk_bundled = __commonJS({
26068
26068
  }
26069
26069
  return new csd(a10);
26070
26070
  }
26071
- function fs11(a10) {
26071
+ function fs9(a10) {
26072
26072
  while (!a10.d || !a10.d.Ob()) {
26073
26073
  if (!!a10.b && !nmb(a10.b)) {
26074
26074
  a10.d = RD(smb(a10.b), 51);
@@ -40459,7 +40459,7 @@ var require_elk_bundled = __commonJS({
40459
40459
  function gs(a10) {
40460
40460
  var b;
40461
40461
  while (!RD(Qb(a10.a), 51).Ob()) {
40462
- a10.d = fs11(a10);
40462
+ a10.d = fs9(a10);
40463
40463
  if (!a10.d) {
40464
40464
  return false;
40465
40465
  }
@@ -111773,8 +111773,8 @@ var require_server_node = __commonJS({
111773
111773
  });
111774
111774
 
111775
111775
  // src/main.ts
111776
- import * as fs10 from "fs";
111777
- import * as path11 from "path";
111776
+ import * as fs8 from "fs";
111777
+ import * as path9 from "path";
111778
111778
  import { fileURLToPath as fileURLToPath2, pathToFileURL } from "url";
111779
111779
 
111780
111780
  // ../extension/src/webview/diagram/ir.ts
@@ -111899,8 +111899,8 @@ function parseArgs(argv) {
111899
111899
  }
111900
111900
 
111901
111901
  // src/export.ts
111902
- import * as fs9 from "fs";
111903
- import * as path10 from "path";
111902
+ import * as fs7 from "fs";
111903
+ import * as path8 from "path";
111904
111904
  import { fileURLToPath } from "url";
111905
111905
 
111906
111906
  // ../../node_modules/.pnpm/langium@3.5.0/node_modules/langium/lib/index.js
@@ -112791,12 +112791,12 @@ function getInteriorNodes(start2, end) {
112791
112791
  function getCommonParent(a2, b) {
112792
112792
  const aParents = getParentChain(a2);
112793
112793
  const bParents = getParentChain(b);
112794
- let current;
112794
+ let current2;
112795
112795
  for (let i = 0; i < aParents.length && i < bParents.length; i++) {
112796
112796
  const aParent = aParents[i];
112797
112797
  const bParent = bParents[i];
112798
112798
  if (aParent.parent === bParent.parent) {
112799
- current = {
112799
+ current2 = {
112800
112800
  parent: aParent.parent,
112801
112801
  a: aParent.index,
112802
112802
  b: bParent.index
@@ -112805,7 +112805,7 @@ function getCommonParent(a2, b) {
112805
112805
  break;
112806
112806
  }
112807
112807
  }
112808
- return current;
112808
+ return current2;
112809
112809
  }
112810
112810
  function getParentChain(node) {
112811
112811
  const chain = [];
@@ -116567,19 +116567,19 @@ function toKey(value) {
116567
116567
  var toKey_default = toKey;
116568
116568
 
116569
116569
  // ../../node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_baseGet.js
116570
- function baseGet(object, path12) {
116571
- path12 = castPath_default(path12, object);
116572
- var index2 = 0, length2 = path12.length;
116570
+ function baseGet(object, path10) {
116571
+ path10 = castPath_default(path10, object);
116572
+ var index2 = 0, length2 = path10.length;
116573
116573
  while (object != null && index2 < length2) {
116574
- object = object[toKey_default(path12[index2++])];
116574
+ object = object[toKey_default(path10[index2++])];
116575
116575
  }
116576
116576
  return index2 && index2 == length2 ? object : void 0;
116577
116577
  }
116578
116578
  var baseGet_default = baseGet;
116579
116579
 
116580
116580
  // ../../node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/get.js
116581
- function get(object, path12, defaultValue) {
116582
- var result = object == null ? void 0 : baseGet_default(object, path12);
116581
+ function get(object, path10, defaultValue) {
116582
+ var result = object == null ? void 0 : baseGet_default(object, path10);
116583
116583
  return result === void 0 ? defaultValue : result;
116584
116584
  }
116585
116585
  var get_default = get;
@@ -117491,11 +117491,11 @@ function baseHasIn(object, key) {
117491
117491
  var baseHasIn_default = baseHasIn;
117492
117492
 
117493
117493
  // ../../node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_hasPath.js
117494
- function hasPath(object, path12, hasFunc) {
117495
- path12 = castPath_default(path12, object);
117496
- var index2 = -1, length2 = path12.length, result = false;
117494
+ function hasPath(object, path10, hasFunc) {
117495
+ path10 = castPath_default(path10, object);
117496
+ var index2 = -1, length2 = path10.length, result = false;
117497
117497
  while (++index2 < length2) {
117498
- var key = toKey_default(path12[index2]);
117498
+ var key = toKey_default(path10[index2]);
117499
117499
  if (!(result = object != null && hasFunc(object, key))) {
117500
117500
  break;
117501
117501
  }
@@ -117510,21 +117510,21 @@ function hasPath(object, path12, hasFunc) {
117510
117510
  var hasPath_default = hasPath;
117511
117511
 
117512
117512
  // ../../node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/hasIn.js
117513
- function hasIn(object, path12) {
117514
- return object != null && hasPath_default(object, path12, baseHasIn_default);
117513
+ function hasIn(object, path10) {
117514
+ return object != null && hasPath_default(object, path10, baseHasIn_default);
117515
117515
  }
117516
117516
  var hasIn_default = hasIn;
117517
117517
 
117518
117518
  // ../../node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_baseMatchesProperty.js
117519
117519
  var COMPARE_PARTIAL_FLAG6 = 1;
117520
117520
  var COMPARE_UNORDERED_FLAG4 = 2;
117521
- function baseMatchesProperty(path12, srcValue) {
117522
- if (isKey_default(path12) && isStrictComparable_default(srcValue)) {
117523
- return matchesStrictComparable_default(toKey_default(path12), srcValue);
117521
+ function baseMatchesProperty(path10, srcValue) {
117522
+ if (isKey_default(path10) && isStrictComparable_default(srcValue)) {
117523
+ return matchesStrictComparable_default(toKey_default(path10), srcValue);
117524
117524
  }
117525
117525
  return function(object) {
117526
- var objValue = get_default(object, path12);
117527
- return objValue === void 0 && objValue === srcValue ? hasIn_default(object, path12) : baseIsEqual_default(srcValue, objValue, COMPARE_PARTIAL_FLAG6 | COMPARE_UNORDERED_FLAG4);
117526
+ var objValue = get_default(object, path10);
117527
+ return objValue === void 0 && objValue === srcValue ? hasIn_default(object, path10) : baseIsEqual_default(srcValue, objValue, COMPARE_PARTIAL_FLAG6 | COMPARE_UNORDERED_FLAG4);
117528
117528
  };
117529
117529
  }
117530
117530
  var baseMatchesProperty_default = baseMatchesProperty;
@@ -117538,16 +117538,16 @@ function baseProperty(key) {
117538
117538
  var baseProperty_default = baseProperty;
117539
117539
 
117540
117540
  // ../../node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_basePropertyDeep.js
117541
- function basePropertyDeep(path12) {
117541
+ function basePropertyDeep(path10) {
117542
117542
  return function(object) {
117543
- return baseGet_default(object, path12);
117543
+ return baseGet_default(object, path10);
117544
117544
  };
117545
117545
  }
117546
117546
  var basePropertyDeep_default = basePropertyDeep;
117547
117547
 
117548
117548
  // ../../node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/property.js
117549
- function property(path12) {
117550
- return isKey_default(path12) ? baseProperty_default(toKey_default(path12)) : basePropertyDeep_default(path12);
117549
+ function property(path10) {
117550
+ return isKey_default(path10) ? baseProperty_default(toKey_default(path10)) : basePropertyDeep_default(path10);
117551
117551
  }
117552
117552
  var property_default = property;
117553
117553
 
@@ -117915,8 +117915,8 @@ function baseHas(object, key) {
117915
117915
  var baseHas_default = baseHas;
117916
117916
 
117917
117917
  // ../../node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/has.js
117918
- function has(object, path12) {
117919
- return object != null && hasPath_default(object, path12, baseHas_default);
117918
+ function has(object, path10) {
117919
+ return object != null && hasPath_default(object, path10, baseHas_default);
117920
117920
  }
117921
117921
  var has_default = has;
117922
117922
 
@@ -118039,14 +118039,14 @@ function negate(predicate) {
118039
118039
  var negate_default = negate;
118040
118040
 
118041
118041
  // ../../node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_baseSet.js
118042
- function baseSet(object, path12, value, customizer) {
118042
+ function baseSet(object, path10, value, customizer) {
118043
118043
  if (!isObject_default(object)) {
118044
118044
  return object;
118045
118045
  }
118046
- path12 = castPath_default(path12, object);
118047
- var index2 = -1, length2 = path12.length, lastIndex = length2 - 1, nested = object;
118046
+ path10 = castPath_default(path10, object);
118047
+ var index2 = -1, length2 = path10.length, lastIndex = length2 - 1, nested = object;
118048
118048
  while (nested != null && ++index2 < length2) {
118049
- var key = toKey_default(path12[index2]), newValue = value;
118049
+ var key = toKey_default(path10[index2]), newValue = value;
118050
118050
  if (key === "__proto__" || key === "constructor" || key === "prototype") {
118051
118051
  return object;
118052
118052
  }
@@ -118054,7 +118054,7 @@ function baseSet(object, path12, value, customizer) {
118054
118054
  var objValue = nested[key];
118055
118055
  newValue = customizer ? customizer(objValue, key, nested) : void 0;
118056
118056
  if (newValue === void 0) {
118057
- newValue = isObject_default(objValue) ? objValue : isIndex_default(path12[index2 + 1]) ? [] : {};
118057
+ newValue = isObject_default(objValue) ? objValue : isIndex_default(path10[index2 + 1]) ? [] : {};
118058
118058
  }
118059
118059
  }
118060
118060
  assignValue_default(nested, key, newValue);
@@ -118068,9 +118068,9 @@ var baseSet_default = baseSet;
118068
118068
  function basePickBy(object, paths, predicate) {
118069
118069
  var index2 = -1, length2 = paths.length, result = {};
118070
118070
  while (++index2 < length2) {
118071
- var path12 = paths[index2], value = baseGet_default(object, path12);
118072
- if (predicate(value, path12)) {
118073
- baseSet_default(result, castPath_default(path12, object), value);
118071
+ var path10 = paths[index2], value = baseGet_default(object, path10);
118072
+ if (predicate(value, path10)) {
118073
+ baseSet_default(result, castPath_default(path10, object), value);
118074
118074
  }
118075
118075
  }
118076
118076
  return result;
@@ -118086,8 +118086,8 @@ function pickBy(object, predicate) {
118086
118086
  return [prop];
118087
118087
  });
118088
118088
  predicate = baseIteratee_default(predicate);
118089
- return basePickBy_default(object, props, function(value, path12) {
118090
- return predicate(value, path12[0]);
118089
+ return basePickBy_default(object, props, function(value, path10) {
118090
+ return predicate(value, path10[0]);
118091
118091
  });
118092
118092
  }
118093
118093
  var pickBy_default = pickBy;
@@ -119685,12 +119685,12 @@ function assignCategoriesMapProp(tokenTypes) {
119685
119685
  singleAssignCategoriesToksMap([], currTokType);
119686
119686
  });
119687
119687
  }
119688
- function singleAssignCategoriesToksMap(path12, nextNode) {
119689
- forEach_default(path12, (pathNode) => {
119688
+ function singleAssignCategoriesToksMap(path10, nextNode) {
119689
+ forEach_default(path10, (pathNode) => {
119690
119690
  nextNode.categoryMatchesMap[pathNode.tokenTypeIdx] = true;
119691
119691
  });
119692
119692
  forEach_default(nextNode.CATEGORIES, (nextCategory) => {
119693
- const newPath = path12.concat(nextNode);
119693
+ const newPath = path10.concat(nextNode);
119694
119694
  if (!includes_default(newPath, nextCategory)) {
119695
119695
  singleAssignCategoriesToksMap(newPath, nextCategory);
119696
119696
  }
@@ -120534,10 +120534,10 @@ var GastRefResolverVisitor = class extends GAstVisitor {
120534
120534
 
120535
120535
  // ../../node_modules/.pnpm/chevrotain@11.0.3/node_modules/chevrotain/lib/src/parse/grammar/interpreter.js
120536
120536
  var AbstractNextPossibleTokensWalker = class extends RestWalker {
120537
- constructor(topProd, path12) {
120537
+ constructor(topProd, path10) {
120538
120538
  super();
120539
120539
  this.topProd = topProd;
120540
- this.path = path12;
120540
+ this.path = path10;
120541
120541
  this.possibleTokTypes = [];
120542
120542
  this.nextProductionName = "";
120543
120543
  this.nextProductionOccurrence = 0;
@@ -120581,9 +120581,9 @@ var AbstractNextPossibleTokensWalker = class extends RestWalker {
120581
120581
  }
120582
120582
  };
120583
120583
  var NextAfterTokenWalker = class extends AbstractNextPossibleTokensWalker {
120584
- constructor(topProd, path12) {
120585
- super(topProd, path12);
120586
- this.path = path12;
120584
+ constructor(topProd, path10) {
120585
+ super(topProd, path10);
120586
+ this.path = path10;
120587
120587
  this.nextTerminalName = "";
120588
120588
  this.nextTerminalOccurrence = 0;
120589
120589
  this.nextTerminalName = this.path.lastTok.name;
@@ -121188,10 +121188,10 @@ function initializeArrayOfArrays(size) {
121188
121188
  }
121189
121189
  return result;
121190
121190
  }
121191
- function pathToHashKeys(path12) {
121191
+ function pathToHashKeys(path10) {
121192
121192
  let keys3 = [""];
121193
- for (let i = 0; i < path12.length; i++) {
121194
- const tokType = path12[i];
121193
+ for (let i = 0; i < path10.length; i++) {
121194
+ const tokType = path10[i];
121195
121195
  const longerKeys = [];
121196
121196
  for (let j = 0; j < keys3.length; j++) {
121197
121197
  const currShorterKey = keys3[j];
@@ -121430,7 +121430,7 @@ function validateRuleIsOverridden(ruleName, definedRulesNames, className) {
121430
121430
  }
121431
121431
  return errors;
121432
121432
  }
121433
- function validateNoLeftRecursion(topRule, currRule, errMsgProvider, path12 = []) {
121433
+ function validateNoLeftRecursion(topRule, currRule, errMsgProvider, path10 = []) {
121434
121434
  const errors = [];
121435
121435
  const nextNonTerminals = getFirstNoneTerminal(currRule.definition);
121436
121436
  if (isEmpty_default(nextNonTerminals)) {
@@ -121442,15 +121442,15 @@ function validateNoLeftRecursion(topRule, currRule, errMsgProvider, path12 = [])
121442
121442
  errors.push({
121443
121443
  message: errMsgProvider.buildLeftRecursionError({
121444
121444
  topLevelRule: topRule,
121445
- leftRecursionPath: path12
121445
+ leftRecursionPath: path10
121446
121446
  }),
121447
121447
  type: ParserDefinitionErrorType.LEFT_RECURSION,
121448
121448
  ruleName
121449
121449
  });
121450
121450
  }
121451
- const validNextSteps = difference_default(nextNonTerminals, path12.concat([topRule]));
121451
+ const validNextSteps = difference_default(nextNonTerminals, path10.concat([topRule]));
121452
121452
  const errorsFromNextSteps = flatMap_default(validNextSteps, (currRefRule) => {
121453
- const newPath = clone_default(path12);
121453
+ const newPath = clone_default(path10);
121454
121454
  newPath.push(currRefRule);
121455
121455
  return validateNoLeftRecursion(topRule, currRefRule, errMsgProvider, newPath);
121456
121456
  });
@@ -125058,19 +125058,19 @@ function toKey2(value) {
125058
125058
  var toKey_default2 = toKey2;
125059
125059
 
125060
125060
  // ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_baseGet.js
125061
- function baseGet2(object, path12) {
125062
- path12 = castPath_default2(path12, object);
125063
- var index2 = 0, length2 = path12.length;
125061
+ function baseGet2(object, path10) {
125062
+ path10 = castPath_default2(path10, object);
125063
+ var index2 = 0, length2 = path10.length;
125064
125064
  while (object != null && index2 < length2) {
125065
- object = object[toKey_default2(path12[index2++])];
125065
+ object = object[toKey_default2(path10[index2++])];
125066
125066
  }
125067
125067
  return index2 && index2 == length2 ? object : void 0;
125068
125068
  }
125069
125069
  var baseGet_default2 = baseGet2;
125070
125070
 
125071
125071
  // ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/get.js
125072
- function get2(object, path12, defaultValue) {
125073
- var result = object == null ? void 0 : baseGet_default2(object, path12);
125072
+ function get2(object, path10, defaultValue) {
125073
+ var result = object == null ? void 0 : baseGet_default2(object, path10);
125074
125074
  return result === void 0 ? defaultValue : result;
125075
125075
  }
125076
125076
  var get_default2 = get2;
@@ -125082,11 +125082,11 @@ function baseHasIn2(object, key) {
125082
125082
  var baseHasIn_default2 = baseHasIn2;
125083
125083
 
125084
125084
  // ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_hasPath.js
125085
- function hasPath2(object, path12, hasFunc) {
125086
- path12 = castPath_default2(path12, object);
125087
- var index2 = -1, length2 = path12.length, result = false;
125085
+ function hasPath2(object, path10, hasFunc) {
125086
+ path10 = castPath_default2(path10, object);
125087
+ var index2 = -1, length2 = path10.length, result = false;
125088
125088
  while (++index2 < length2) {
125089
- var key = toKey_default2(path12[index2]);
125089
+ var key = toKey_default2(path10[index2]);
125090
125090
  if (!(result = object != null && hasFunc(object, key))) {
125091
125091
  break;
125092
125092
  }
@@ -125101,21 +125101,21 @@ function hasPath2(object, path12, hasFunc) {
125101
125101
  var hasPath_default2 = hasPath2;
125102
125102
 
125103
125103
  // ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/hasIn.js
125104
- function hasIn2(object, path12) {
125105
- return object != null && hasPath_default2(object, path12, baseHasIn_default2);
125104
+ function hasIn2(object, path10) {
125105
+ return object != null && hasPath_default2(object, path10, baseHasIn_default2);
125106
125106
  }
125107
125107
  var hasIn_default2 = hasIn2;
125108
125108
 
125109
125109
  // ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_baseMatchesProperty.js
125110
125110
  var COMPARE_PARTIAL_FLAG12 = 1;
125111
125111
  var COMPARE_UNORDERED_FLAG8 = 2;
125112
- function baseMatchesProperty2(path12, srcValue) {
125113
- if (isKey_default2(path12) && isStrictComparable_default2(srcValue)) {
125114
- return matchesStrictComparable_default2(toKey_default2(path12), srcValue);
125112
+ function baseMatchesProperty2(path10, srcValue) {
125113
+ if (isKey_default2(path10) && isStrictComparable_default2(srcValue)) {
125114
+ return matchesStrictComparable_default2(toKey_default2(path10), srcValue);
125115
125115
  }
125116
125116
  return function(object) {
125117
- var objValue = get_default2(object, path12);
125118
- return objValue === void 0 && objValue === srcValue ? hasIn_default2(object, path12) : baseIsEqual_default2(srcValue, objValue, COMPARE_PARTIAL_FLAG12 | COMPARE_UNORDERED_FLAG8);
125117
+ var objValue = get_default2(object, path10);
125118
+ return objValue === void 0 && objValue === srcValue ? hasIn_default2(object, path10) : baseIsEqual_default2(srcValue, objValue, COMPARE_PARTIAL_FLAG12 | COMPARE_UNORDERED_FLAG8);
125119
125119
  };
125120
125120
  }
125121
125121
  var baseMatchesProperty_default2 = baseMatchesProperty2;
@@ -125135,16 +125135,16 @@ function baseProperty2(key) {
125135
125135
  var baseProperty_default2 = baseProperty2;
125136
125136
 
125137
125137
  // ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/_basePropertyDeep.js
125138
- function basePropertyDeep2(path12) {
125138
+ function basePropertyDeep2(path10) {
125139
125139
  return function(object) {
125140
- return baseGet_default2(object, path12);
125140
+ return baseGet_default2(object, path10);
125141
125141
  };
125142
125142
  }
125143
125143
  var basePropertyDeep_default2 = basePropertyDeep2;
125144
125144
 
125145
125145
  // ../../node_modules/.pnpm/lodash-es@4.18.1/node_modules/lodash-es/property.js
125146
- function property2(path12) {
125147
- return isKey_default2(path12) ? baseProperty_default2(toKey_default2(path12)) : basePropertyDeep_default2(path12);
125146
+ function property2(path10) {
125147
+ return isKey_default2(path10) ? baseProperty_default2(toKey_default2(path10)) : basePropertyDeep_default2(path10);
125148
125148
  }
125149
125149
  var property_default2 = property2;
125150
125150
 
@@ -125657,9 +125657,9 @@ function getATNConfigKey(config, alt = true) {
125657
125657
  function baseExtremum(array2, iteratee, comparator) {
125658
125658
  var index2 = -1, length2 = array2.length;
125659
125659
  while (++index2 < length2) {
125660
- var value = array2[index2], current = iteratee(value);
125661
- if (current != null && (computed === void 0 ? current === current && !isSymbol_default2(current) : comparator(current, computed))) {
125662
- var computed = current, result = value;
125660
+ var value = array2[index2], current2 = iteratee(value);
125661
+ if (current2 != null && (computed === void 0 ? current2 === current2 && !isSymbol_default2(current2) : comparator(current2, computed))) {
125662
+ var computed = current2, result = value;
125663
125663
  }
125664
125664
  }
125665
125665
  return result;
@@ -125985,7 +125985,7 @@ var LLStarLookaheadStrategy = class extends LLkLookaheadStrategy {
125985
125985
  occurrence: prodOccurrence,
125986
125986
  prodType: "Alternation",
125987
125987
  rule
125988
- }), (currAlt) => map_default2(currAlt, (path12) => path12[0]));
125988
+ }), (currAlt) => map_default2(currAlt, (path10) => path10[0]));
125989
125989
  if (isLL1Sequence(partialAlts, false) && !dynamicTokensEnabled) {
125990
125990
  const choiceToAlt = reduce_default2(partialAlts, (result, currAlt, idx) => {
125991
125991
  forEach_default2(currAlt, (currTokType) => {
@@ -126130,7 +126130,7 @@ function adaptivePredict(dfaCaches, decision, predicateSet, logging) {
126130
126130
  function performLookahead(dfa, s0, predicateSet, logging) {
126131
126131
  let previousD = s0;
126132
126132
  let i = 1;
126133
- const path12 = [];
126133
+ const path10 = [];
126134
126134
  let t = this.LA(i++);
126135
126135
  while (true) {
126136
126136
  let d = getExistingTargetState(previousD, t);
@@ -126138,13 +126138,13 @@ function performLookahead(dfa, s0, predicateSet, logging) {
126138
126138
  d = computeLookaheadTarget.apply(this, [dfa, previousD, t, i, predicateSet, logging]);
126139
126139
  }
126140
126140
  if (d === DFA_ERROR) {
126141
- return buildAdaptivePredictError(path12, previousD, t);
126141
+ return buildAdaptivePredictError(path10, previousD, t);
126142
126142
  }
126143
126143
  if (d.isAcceptState === true) {
126144
126144
  return d.prediction;
126145
126145
  }
126146
126146
  previousD = d;
126147
- path12.push(t);
126147
+ path10.push(t);
126148
126148
  t = this.LA(i++);
126149
126149
  }
126150
126150
  }
@@ -126217,13 +126217,13 @@ function getProductionDslName2(prod) {
126217
126217
  throw Error("non exhaustive match");
126218
126218
  }
126219
126219
  }
126220
- function buildAdaptivePredictError(path12, previous, current) {
126220
+ function buildAdaptivePredictError(path10, previous, current2) {
126221
126221
  const nextTransitions = flatMap_default2(previous.configs.elements, (e) => e.state.transitions);
126222
126222
  const nextTokenTypes = uniqBy_default(nextTransitions.filter((e) => e instanceof AtomTransition).map((e) => e.tokenType), (e) => e.tokenTypeIdx);
126223
126223
  return {
126224
- actualToken: current,
126224
+ actualToken: current2,
126225
126225
  possibleTokenTypes: nextTokenTypes,
126226
- tokenPath: path12
126226
+ tokenPath: path10
126227
126227
  };
126228
126228
  }
126229
126229
  function getExistingTargetState(state, token) {
@@ -127658,31 +127658,31 @@ var CstNodeBuilder = class {
127658
127658
  leafNode.root = this.rootNode;
127659
127659
  nodes.push(leafNode);
127660
127660
  }
127661
- let current = this.current;
127661
+ let current2 = this.current;
127662
127662
  let added = false;
127663
- if (current.content.length > 0) {
127664
- current.content.push(...nodes);
127663
+ if (current2.content.length > 0) {
127664
+ current2.content.push(...nodes);
127665
127665
  return;
127666
127666
  }
127667
- while (current.container) {
127668
- const index2 = current.container.content.indexOf(current);
127667
+ while (current2.container) {
127668
+ const index2 = current2.container.content.indexOf(current2);
127669
127669
  if (index2 > 0) {
127670
- current.container.content.splice(index2, 0, ...nodes);
127670
+ current2.container.content.splice(index2, 0, ...nodes);
127671
127671
  added = true;
127672
127672
  break;
127673
127673
  }
127674
- current = current.container;
127674
+ current2 = current2.container;
127675
127675
  }
127676
127676
  if (!added) {
127677
127677
  this.rootNode.content.unshift(...nodes);
127678
127678
  }
127679
127679
  }
127680
127680
  construct(item) {
127681
- const current = this.current;
127681
+ const current2 = this.current;
127682
127682
  if (typeof item.$type === "string") {
127683
127683
  this.current.astNode = item;
127684
127684
  }
127685
- item.$cstNode = current;
127685
+ item.$cstNode = current2;
127686
127686
  const node = this.nodeStack.pop();
127687
127687
  if ((node === null || node === void 0 ? void 0 : node.content.length) === 0) {
127688
127688
  this.removeNode(node);
@@ -127980,16 +127980,16 @@ var LangiumParser = class extends AbstractLangiumParser {
127980
127980
  this.nodeBuilder.addHiddenNodes(hiddenTokens);
127981
127981
  const leafNode = this.nodeBuilder.buildLeafNode(token, feature);
127982
127982
  const { assignment, isCrossRef } = this.getAssignment(feature);
127983
- const current = this.current;
127983
+ const current2 = this.current;
127984
127984
  if (assignment) {
127985
127985
  const convertedValue = isKeyword(feature) ? token.image : this.converter.convert(token.image, leafNode);
127986
127986
  this.assign(assignment.operator, assignment.feature, convertedValue, leafNode, isCrossRef);
127987
- } else if (isDataTypeNode(current)) {
127987
+ } else if (isDataTypeNode(current2)) {
127988
127988
  let text = token.image;
127989
127989
  if (!isKeyword(feature)) {
127990
127990
  text = this.converter.convert(text, leafNode).toString();
127991
127991
  }
127992
- current.value += text;
127992
+ current2.value += text;
127993
127993
  }
127994
127994
  }
127995
127995
  }
@@ -128026,11 +128026,11 @@ var LangiumParser = class extends AbstractLangiumParser {
128026
128026
  if (assignment) {
128027
128027
  this.assign(assignment.operator, assignment.feature, result, cstNode, isCrossRef);
128028
128028
  } else if (!assignment) {
128029
- const current = this.current;
128030
- if (isDataTypeNode(current)) {
128031
- current.value += result.toString();
128029
+ const current2 = this.current;
128030
+ if (isDataTypeNode(current2)) {
128031
+ current2.value += result.toString();
128032
128032
  } else if (typeof result === "object" && result) {
128033
- const object = this.assignWithoutOverride(result, current);
128033
+ const object = this.assignWithoutOverride(result, current2);
128034
128034
  const newItem = object;
128035
128035
  this.stack.pop();
128036
128036
  this.stack.push(newItem);
@@ -128855,9 +128855,9 @@ async function interruptAndCheck(token) {
128855
128855
  if (token === cancellation_exports.CancellationToken.None) {
128856
128856
  return;
128857
128857
  }
128858
- const current = performance.now();
128859
- if (current - lastTick >= globalInterruptionPeriod) {
128860
- lastTick = current;
128858
+ const current2 = performance.now();
128859
+ if (current2 - lastTick >= globalInterruptionPeriod) {
128860
+ lastTick = current2;
128861
128861
  await delayNextTick();
128862
128862
  lastTick = performance.now();
128863
128863
  }
@@ -129454,7 +129454,7 @@ var UriUtils;
129454
129454
  return (a2 === null || a2 === void 0 ? void 0 : a2.toString()) === (b === null || b === void 0 ? void 0 : b.toString());
129455
129455
  }
129456
129456
  UriUtils2.equals = equals;
129457
- function relative4(from, to) {
129457
+ function relative3(from, to) {
129458
129458
  const fromPath = typeof from === "string" ? URI2.parse(from).path : from.path;
129459
129459
  const toPath = typeof to === "string" ? URI2.parse(to).path : to.path;
129460
129460
  const fromParts = fromPath.split("/").filter((e) => e.length > 0);
@@ -129481,7 +129481,7 @@ var UriUtils;
129481
129481
  const toPart = toParts.slice(i).join("/");
129482
129482
  return backPart + toPart;
129483
129483
  }
129484
- UriUtils2.relative = relative4;
129484
+ UriUtils2.relative = relative3;
129485
129485
  function normalize2(uri) {
129486
129486
  return URI2.parse(uri.toString()).toString();
129487
129487
  }
@@ -129897,12 +129897,12 @@ var DefaultReferences = class {
129897
129897
  const nameNode = this.nameProvider.getNameNode(targetNode);
129898
129898
  if (nameNode) {
129899
129899
  const doc = getDocument(targetNode);
129900
- const path12 = this.nodeLocator.getAstNodePath(targetNode);
129900
+ const path10 = this.nodeLocator.getAstNodePath(targetNode);
129901
129901
  return {
129902
129902
  sourceUri: doc.uri,
129903
- sourcePath: path12,
129903
+ sourcePath: path10,
129904
129904
  targetUri: doc.uri,
129905
- targetPath: path12,
129905
+ targetPath: path10,
129906
129906
  segment: toDocumentSegment(nameNode),
129907
129907
  local: true
129908
129908
  };
@@ -131081,9 +131081,9 @@ var DefaultAstNodeDescriptionProvider = class {
131081
131081
  createDescription(node, name, document2) {
131082
131082
  const doc = document2 !== null && document2 !== void 0 ? document2 : getDocument(node);
131083
131083
  name !== null && name !== void 0 ? name : name = this.nameProvider.getName(node);
131084
- const path12 = this.astNodeLocator.getAstNodePath(node);
131084
+ const path10 = this.astNodeLocator.getAstNodePath(node);
131085
131085
  if (!name) {
131086
- throw new Error(`Node at path ${path12} has no name.`);
131086
+ throw new Error(`Node at path ${path10} has no name.`);
131087
131087
  }
131088
131088
  let nameNodeSegment;
131089
131089
  const nameSegmentGetter = () => {
@@ -131099,7 +131099,7 @@ var DefaultAstNodeDescriptionProvider = class {
131099
131099
  selectionSegment: toDocumentSegment(node.$cstNode),
131100
131100
  type: node.$type,
131101
131101
  documentUri: doc.uri,
131102
- path: path12
131102
+ path: path10
131103
131103
  };
131104
131104
  }
131105
131105
  };
@@ -131163,8 +131163,8 @@ var DefaultAstNodeLocator = class {
131163
131163
  }
131164
131164
  return $containerProperty;
131165
131165
  }
131166
- getAstNode(node, path12) {
131167
- const segments = path12.split(this.segmentSeparator);
131166
+ getAstNode(node, path10) {
131167
+ const segments = path10.split(this.segmentSeparator);
131168
131168
  return segments.reduce((previousValue, currentValue) => {
131169
131169
  if (!previousValue || currentValue.length === 0) {
131170
131170
  return previousValue;
@@ -158770,9 +158770,9 @@ var DefaultFuzzyMatcher = class {
158770
158770
  }
158771
158771
  return false;
158772
158772
  }
158773
- isWordTransition(previous, current) {
158774
- return a <= previous && previous <= z && A <= current && current <= Z || // camelCase transition
158775
- previous === _ && current !== _;
158773
+ isWordTransition(previous, current2) {
158774
+ return a <= previous && previous <= z && A <= current2 && current2 <= Z || // camelCase transition
158775
+ previous === _ && current2 !== _;
158776
158776
  }
158777
158777
  toUpperCharCode(charCode) {
158778
158778
  if (a <= charCode && charCode <= z) {
@@ -161661,22 +161661,22 @@ var SysmlDiagramModelProvider = class _SysmlDiagramModelProvider {
161661
161661
  const segments = text.split(/::|\./u).filter(Boolean);
161662
161662
  if (segments.length === 0)
161663
161663
  return void 0;
161664
- let current = all.find((n) => isPartDecl(n) && nameOf(n) === segments[0] && this.isDirectPackageMember(n));
161665
- current ??= all.find((n) => isPartDecl(n) && nameOf(n) === segments[0]);
161664
+ let current2 = all.find((n) => isPartDecl(n) && nameOf(n) === segments[0] && this.isDirectPackageMember(n));
161665
+ current2 ??= all.find((n) => isPartDecl(n) && nameOf(n) === segments[0]);
161666
161666
  for (const segment of segments.slice(1)) {
161667
- const direct = current && membersOf(current).find((m) => isPartDecl(m) && nameOf(m) === segment);
161668
- const type = current ? this.resolveType(current, index2) : void 0;
161667
+ const direct = current2 && membersOf(current2).find((m) => isPartDecl(m) && nameOf(m) === segment);
161668
+ const type = current2 ? this.resolveType(current2, index2) : void 0;
161669
161669
  const inherited = type && membersOf(type).find((m) => isPartDecl(m) && nameOf(m) === segment);
161670
- current = direct ?? inherited;
161671
- if (!current)
161670
+ current2 = direct ?? inherited;
161671
+ if (!current2)
161672
161672
  return void 0;
161673
161673
  }
161674
- return current;
161674
+ return current2;
161675
161675
  };
161676
161676
  const drawnOwnerNodes = /* @__PURE__ */ new Set([...defNodes, ...packageUsageNodes]);
161677
161677
  const belongsToDrawnFeatureTree = (node) => {
161678
- for (let current = node.$container; current; current = current.$container) {
161679
- if (drawnOwnerNodes.has(current))
161678
+ for (let current2 = node.$container; current2; current2 = current2.$container) {
161679
+ if (drawnOwnerNodes.has(current2))
161680
161680
  return true;
161681
161681
  }
161682
161682
  return false;
@@ -161846,8 +161846,8 @@ var SysmlDiagramModelProvider = class _SysmlDiagramModelProvider {
161846
161846
  if (ids.has(node))
161847
161847
  return node;
161848
161848
  }
161849
- const path12 = this.featurePath(value) ?? String(value ?? "");
161850
- return byName.get(lastSeg(path12));
161849
+ const path10 = this.featurePath(value) ?? String(value ?? "");
161850
+ return byName.get(lastSeg(path10));
161851
161851
  };
161852
161852
  const pushPathEdge = (fromValue, toValue, kind, label, src) => {
161853
161853
  const from = drawnByPath(fromValue);
@@ -161971,8 +161971,8 @@ var SysmlDiagramModelProvider = class _SysmlDiagramModelProvider {
161971
161971
  edges.push({ id: `e${e++}`, from: hubId, to: ids.get(supplier), kind: "dependency", meta: { dependencyRole: "supplier" }, source: sourceOf2(dep, uri) });
161972
161972
  }
161973
161973
  }
161974
- const resolveDrawnPathTarget = (path12) => {
161975
- const segs = path12.replace(/\[.*$/, "").split("::").map((s) => s.replace(/[*]+/g, "").trim()).filter(Boolean);
161974
+ const resolveDrawnPathTarget = (path10) => {
161975
+ const segs = path10.replace(/\[.*$/, "").split("::").map((s) => s.replace(/[*]+/g, "").trim()).filter(Boolean);
161976
161976
  for (let i = segs.length - 1; i >= 0; i -= 1) {
161977
161977
  const cand = byName.get(lastSeg(segs[i]));
161978
161978
  if (cand && ids.has(cand))
@@ -161996,13 +161996,13 @@ var SysmlDiagramModelProvider = class _SysmlDiagramModelProvider {
161996
161996
  if (!owner || !ids.has(owner))
161997
161997
  continue;
161998
161998
  for (const p of ex.paths ?? []) {
161999
- const path12 = (p.$cstNode?.text ?? "").replace(/\s+/g, "").trim();
162000
- if (!path12)
161999
+ const path10 = (p.$cstNode?.text ?? "").replace(/\s+/g, "").trim();
162000
+ if (!path10)
162001
162001
  continue;
162002
- const target = resolveDrawnPathTarget(path12);
162002
+ const target = resolveDrawnPathTarget(path10);
162003
162003
  if (!target || !ids.has(target) || target === owner)
162004
162004
  continue;
162005
- edges.push({ id: `e${e++}`, from: ids.get(owner), to: ids.get(target), kind: "expose", label: `\xABexpose\xBB ${path12}`, source: sourceOf2(ex, uri) });
162005
+ edges.push({ id: `e${e++}`, from: ids.get(owner), to: ids.get(target), kind: "expose", label: `\xABexpose\xBB ${path10}`, source: sourceOf2(ex, uri) });
162006
162006
  }
162007
162007
  }
162008
162008
  let derivationCount = 0;
@@ -162968,10 +162968,10 @@ var SysmlDiagramModelProvider = class _SysmlDiagramModelProvider {
162968
162968
  return "__initial__";
162969
162969
  return byName.get(key);
162970
162970
  };
162971
- const resolvePin = (path12) => {
162972
- if (!path12)
162971
+ const resolvePin = (path10) => {
162972
+ if (!path10)
162973
162973
  return void 0;
162974
- const normalized = normalizePinPath(path12);
162974
+ const normalized = normalizePinPath(path10);
162975
162975
  const exact = pinByPath.get(normalized);
162976
162976
  if (exact)
162977
162977
  return exact;
@@ -163045,12 +163045,12 @@ var SysmlDiagramModelProvider = class _SysmlDiagramModelProvider {
163045
163045
  }
163046
163046
  };
163047
163047
  const processMembers = (holder, incoming) => {
163048
- let current = incoming;
163048
+ let current2 = incoming;
163049
163049
  let branchSource = isBranchSource(incoming) ? incoming : void 0;
163050
163050
  const setCurrent = (id2) => {
163051
163051
  if (!id2)
163052
163052
  return;
163053
- current = id2;
163053
+ current2 = id2;
163054
163054
  branchSource = isBranchSource(id2) ? id2 : void 0;
163055
163055
  };
163056
163056
  for (const m of membersOf(holder)) {
@@ -163086,7 +163086,7 @@ var SysmlDiagramModelProvider = class _SysmlDiagramModelProvider {
163086
163086
  const child = thenMemberNode(m);
163087
163087
  const childId = child ? idByNode.get(child) : void 0;
163088
163088
  const to = childId ?? resolveStep(pathText(tm.target));
163089
- const source = current;
163089
+ const source = current2;
163090
163090
  if (linkIds(source, to, void 0, m))
163091
163091
  sequenced = true;
163092
163092
  if (source && isBranchSource(source)) {
@@ -163101,9 +163101,9 @@ var SysmlDiagramModelProvider = class _SysmlDiagramModelProvider {
163101
163101
  }
163102
163102
  } else if (m.$type === "IfActionNode" && m.thenTarget) {
163103
163103
  const inf = m;
163104
- linkTarget(branchSource ?? current, inf.thenTarget, guardLabel(inf.cond), m);
163104
+ linkTarget(branchSource ?? current2, inf.thenTarget, guardLabel(inf.cond), m);
163105
163105
  } else if (m.$type === "ElseSuccessionMember") {
163106
- linkTarget(branchSource ?? current, m.target, "else", m);
163106
+ linkTarget(branchSource ?? current2, m.target, "else", m);
163107
163107
  } else if (m.$type === "FlowStmt" && m.flowKind === "flow") {
163108
163108
  const fm = m;
163109
163109
  const ends = this.flowStmtEnds(fm);
@@ -163119,10 +163119,10 @@ var SysmlDiagramModelProvider = class _SysmlDiagramModelProvider {
163119
163119
  emitStructuredBranches(m, id2);
163120
163120
  }
163121
163121
  for (const block2 of actionBlocksOf(m))
163122
- processMembers(block2, id2 ?? current);
163122
+ processMembers(block2, id2 ?? current2);
163123
163123
  }
163124
163124
  }
163125
- return current;
163125
+ return current2;
163126
163126
  };
163127
163127
  processMembers(anchor);
163128
163128
  const sends = actionRecords.filter((r) => r.m.$type === "SendNode");
@@ -163315,11 +163315,11 @@ var SysmlDiagramModelProvider = class _SysmlDiagramModelProvider {
163315
163315
  if (chain.length)
163316
163316
  eventChains.set(id2, chain);
163317
163317
  }
163318
- const resolveLifeline = (path12) => path12 ? byName.get(path12.split(".")[0]) : void 0;
163319
- const eventOf = (path12, lifeline) => {
163320
- if (!path12 || !lifeline)
163318
+ const resolveLifeline = (path10) => path10 ? byName.get(path10.split(".")[0]) : void 0;
163319
+ const eventOf = (path10, lifeline) => {
163320
+ if (!path10 || !lifeline)
163321
163321
  return void 0;
163322
- const segs = path12.split(".");
163322
+ const segs = path10.split(".");
163323
163323
  return segs.length >= 2 ? evKey(lifeline, segs[segs.length - 1]) : void 0;
163324
163324
  };
163325
163325
  const msgs = [];
@@ -163909,9 +163909,9 @@ var SysmlDiagramModelProvider = class _SysmlDiagramModelProvider {
163909
163909
  const oq = qnameOf(owner2);
163910
163910
  if (!oq)
163911
163911
  continue;
163912
- const relative4 = byQName.get(`${oq}::${normalized}`);
163913
- if (relative4)
163914
- return qnameOf(relative4);
163912
+ const relative3 = byQName.get(`${oq}::${normalized}`);
163913
+ if (relative3)
163914
+ return qnameOf(relative3);
163915
163915
  }
163916
163916
  const candidates = (bySimple.get(segments[segments.length - 1]) ?? []).filter((candidate) => pathMatchesQName(normalized, qnameOf(candidate)));
163917
163917
  if (candidates.length === 1)
@@ -164687,8 +164687,8 @@ var SysmlDiagramModelProvider = class _SysmlDiagramModelProvider {
164687
164687
  };
164688
164688
 
164689
164689
  // src/services.ts
164690
- import * as fs7 from "fs";
164691
- import * as path7 from "path";
164690
+ import * as fs5 from "fs";
164691
+ import * as path5 from "path";
164692
164692
 
164693
164693
  // ../../node_modules/.pnpm/langium@3.5.0/node_modules/langium/lib/node/node-file-system-provider.js
164694
164694
  import * as fs from "node:fs";
@@ -165127,17 +165127,33 @@ function outlineGroupForType(astType) {
165127
165127
  return CATEGORY_TO_OUTLINE_GROUP[categoryForType(astType)] ?? "structure";
165128
165128
  }
165129
165129
 
165130
+ // ../language-server/out/src/platform/platform.js
165131
+ var current;
165132
+ function setPlatform(platform) {
165133
+ current = platform;
165134
+ }
165135
+ function getPlatform() {
165136
+ if (!current)
165137
+ throw new Error("SysML: no platform installed \u2014 the entry point must call setPlatform() first.");
165138
+ return current;
165139
+ }
165140
+ function hasPlatform() {
165141
+ return current !== void 0;
165142
+ }
165143
+
165130
165144
  // ../language-server/out/src/services/library-index-manager.js
165131
- import * as path from "path";
165132
165145
  var SysmlIndexManager = class extends DefaultIndexManager {
165133
165146
  constructor(services) {
165134
165147
  super(services);
165135
165148
  }
165149
+ // REQ-075, REQ-383 — `libraryRoot` is a URI and the concrete file URIs come
165150
+ // from the platform, because the two hosts index the same library under
165151
+ // different schemes (`file:` on the desktop, `sysml-lib:` in a worker).
165136
165152
  loadPrecomputedLibraryIndex(index2, libraryRoot) {
165153
+ const platform = getPlatform();
165137
165154
  let symbolCount = 0;
165138
165155
  for (const file of index2.files) {
165139
- const filePath = path.join(libraryRoot, ...file.path.split("/"));
165140
- const documentUri = URI2.file(filePath);
165156
+ const documentUri = platform.libraryUri(libraryRoot, file.path);
165141
165157
  const descriptions = file.symbols.map((symbol) => this.deserializeSymbol(symbol, documentUri));
165142
165158
  const uri = documentUri.toString();
165143
165159
  this.symbolIndex.set(uri, descriptions);
@@ -165164,20 +165180,26 @@ function isSysmlIndexManager(value) {
165164
165180
  return typeof value.loadPrecomputedLibraryIndex === "function";
165165
165181
  }
165166
165182
  var libraryRoots = /* @__PURE__ */ new Set();
165183
+ var ROOT_SEPARATOR = "\0";
165167
165184
  function normalizeLibraryPath(p) {
165168
165185
  return p.replace(/\\/gu, "/").replace(/\/+$/u, "").toLowerCase();
165169
165186
  }
165170
- function registerLibraryRoot(dirPath) {
165171
- if (dirPath && dirPath.length > 0)
165172
- libraryRoots.add(normalizeLibraryPath(URI2.file(dirPath).path));
165187
+ function registerLibraryRoot(root4) {
165188
+ const uri = typeof root4 === "string" ? root4.length > 0 ? URI2.file(root4) : void 0 : root4;
165189
+ if (!uri)
165190
+ return;
165191
+ libraryRoots.add(`${uri.scheme}${ROOT_SEPARATOR}${normalizeLibraryPath(uri.path)}`);
165173
165192
  }
165174
165193
  function isInsideDir(fsPath, dir) {
165175
165194
  return fsPath === dir || fsPath.startsWith(`${dir}/`);
165176
165195
  }
165177
165196
  function isStandardLibraryUri(uri) {
165178
165197
  const fsPath = normalizeLibraryPath(uri.path);
165179
- for (const root4 of libraryRoots) {
165180
- if (isInsideDir(fsPath, root4))
165198
+ for (const entry of libraryRoots) {
165199
+ const separator = entry.indexOf(ROOT_SEPARATOR);
165200
+ if (entry.slice(0, separator) !== uri.scheme)
165201
+ continue;
165202
+ if (isInsideDir(fsPath, entry.slice(separator + 1)))
165181
165203
  return true;
165182
165204
  }
165183
165205
  return fsPath.split("/").some((segment) => segment === "sysml.library");
@@ -166697,11 +166719,11 @@ function memberList(node) {
166697
166719
  return lines;
166698
166720
  }
166699
166721
  function nearestAncestor(node, types) {
166700
- let current = node;
166701
- while (current) {
166702
- if (types.has(current.$type))
166703
- return current;
166704
- current = current.$container;
166722
+ let current2 = node;
166723
+ while (current2) {
166724
+ if (types.has(current2.$type))
166725
+ return current2;
166726
+ current2 = current2.$container;
166705
166727
  }
166706
166728
  return void 0;
166707
166729
  }
@@ -168069,8 +168091,8 @@ var SysmlCompletionProvider = class extends DefaultCompletionProvider {
168069
168091
  const root4 = document2.parseResult.value;
168070
168092
  const enclosing = smallestNodeAtOffset(root4, offset);
168071
168093
  const owner = nearestMemberOwner(enclosing) ?? root4;
168072
- return collectReachablePorts(owner).map((path12) => ({
168073
- label: path12,
168094
+ return collectReachablePorts(owner).map((path10) => ({
168095
+ label: path10,
168074
168096
  kind: import_vscode_languageserver14.CompletionItemKind.Interface,
168075
168097
  detail: "Reachable port",
168076
168098
  sortText: "0"
@@ -168299,13 +168321,13 @@ function typingTarget(node) {
168299
168321
  return findNamedNode(ast_utils_exports.getDocument(node).parseResult.value, simpleName(refText), { definitionsOnly: true });
168300
168322
  }
168301
168323
  function resolveReceiverMembers(root4, receiver) {
168302
- let current = findNamedNode(root4, simpleName(receiver.split(/[.:]+/u)[0]));
168324
+ let current2 = findNamedNode(root4, simpleName(receiver.split(/[.:]+/u)[0]));
168303
168325
  for (const segment of receiver.split(/(?:\.|::)/u).slice(1)) {
168304
- current = collectMembersWithTyped(current).find((member) => nodeName(member) === segment);
168305
- if (!current)
168326
+ current2 = collectMembersWithTyped(current2).find((member) => nodeName(member) === segment);
168327
+ if (!current2)
168306
168328
  return [];
168307
168329
  }
168308
- return collectMembersWithTyped(current);
168330
+ return collectMembersWithTyped(current2);
168309
168331
  }
168310
168332
  function collectMembersWithTyped(node) {
168311
168333
  if (!node)
@@ -168358,11 +168380,11 @@ function smallestNodeAtOffset(root4, offset) {
168358
168380
  return best;
168359
168381
  }
168360
168382
  function nearestMemberOwner(node) {
168361
- let current = node;
168362
- while (current) {
168363
- if (nodeMembers(current).length > 0 && current.$type !== "Document")
168364
- return current;
168365
- current = current.$container;
168383
+ let current2 = node;
168384
+ while (current2) {
168385
+ if (nodeMembers(current2).length > 0 && current2.$type !== "Document")
168386
+ return current2;
168387
+ current2 = current2.$container;
168366
168388
  }
168367
168389
  return void 0;
168368
168390
  }
@@ -168610,22 +168632,22 @@ function namespaceMembers(node) {
168610
168632
  return [...n?.elements ?? [], ...n?.members ?? []];
168611
168633
  }
168612
168634
  function expandImportInto(imp, globalDescriptions, out, options, visitedNamespaces) {
168613
- const path12 = importedPath(imp);
168614
- if (!path12)
168635
+ const path10 = importedPath(imp);
168636
+ if (!path10)
168615
168637
  return;
168616
168638
  const start2 = out.length;
168617
- const namedSegments = path12.split("::");
168639
+ const namedSegments = path10.split("::");
168618
168640
  const wildcard = importWildcard(imp);
168619
168641
  if (wildcard === "none") {
168620
- const targetDesc = resolveImportedDescription(path12, globalDescriptions, options, visitedNamespaces);
168642
+ const targetDesc = resolveImportedDescription(path10, globalDescriptions, options, visitedNamespaces);
168621
168643
  if (targetDesc) {
168622
168644
  const alias = imp.alias ?? namedSegments[namedSegments.length - 1];
168623
168645
  if (alias)
168624
168646
  out.push({ name: alias, targetName: targetDesc.name, description: targetDesc });
168625
168647
  }
168626
168648
  } else {
168627
- expandNamespaceMembers(path12, wildcard, globalDescriptions, out);
168628
- expandNamespaceImports(path12, globalDescriptions, out, options, visitedNamespaces);
168649
+ expandNamespaceMembers(path10, wildcard, globalDescriptions, out);
168650
+ expandNamespaceImports(path10, globalDescriptions, out, options, visitedNamespaces);
168629
168651
  }
168630
168652
  applyImportFilters(imp, out, start2, options);
168631
168653
  }
@@ -168724,21 +168746,21 @@ function qualifiedNameMatches(a2, b) {
168724
168746
  }
168725
168747
  return true;
168726
168748
  }
168727
- function resolveImportedDescription(path12, globalDescriptions, options, visitedNamespaces) {
168728
- const direct = globalDescriptions.find((desc) => desc.name === path12);
168749
+ function resolveImportedDescription(path10, globalDescriptions, options, visitedNamespaces) {
168750
+ const direct = globalDescriptions.find((desc) => desc.name === path10);
168729
168751
  if (direct)
168730
168752
  return direct;
168731
- const split = path12.lastIndexOf("::");
168753
+ const split = path10.lastIndexOf("::");
168732
168754
  if (split < 0)
168733
168755
  return void 0;
168734
- const ownerPath = path12.slice(0, split);
168735
- const simpleName2 = path12.slice(split + 2);
168756
+ const ownerPath = path10.slice(0, split);
168757
+ const simpleName2 = path10.slice(split + 2);
168736
168758
  const exported = [];
168737
168759
  expandNamespaceImports(ownerPath, globalDescriptions, exported, options, visitedNamespaces);
168738
168760
  return exported.find((entry) => entry.name === simpleName2)?.description;
168739
168761
  }
168740
- function expandNamespaceMembers(path12, wildcard, globalDescriptions, out) {
168741
- const prefix = path12 + "::";
168762
+ function expandNamespaceMembers(path10, wildcard, globalDescriptions, out) {
168763
+ const prefix = path10 + "::";
168742
168764
  for (const desc of globalDescriptions) {
168743
168765
  if (!desc.name.startsWith(prefix))
168744
168766
  continue;
@@ -168751,9 +168773,9 @@ function expandNamespaceMembers(path12, wildcard, globalDescriptions, out) {
168751
168773
  out.push({ name: simple, targetName: desc.name, description: desc });
168752
168774
  }
168753
168775
  }
168754
- function expandNamespaceImports(path12, globalDescriptions, out, options, visitedNamespaces) {
168776
+ function expandNamespaceImports(path10, globalDescriptions, out, options, visitedNamespaces) {
168755
168777
  for (const namespaceDesc of globalDescriptions) {
168756
- if (namespaceDesc.name !== path12)
168778
+ if (namespaceDesc.name !== path10)
168757
168779
  continue;
168758
168780
  const key = descriptionKey(namespaceDesc);
168759
168781
  if (visitedNamespaces.has(key))
@@ -169891,9 +169913,9 @@ ${baseIndent}}`;
169891
169913
  if (isImport(child)) {
169892
169914
  imports.push(child);
169893
169915
  const alias = child.alias;
169894
- const path12 = importedPath(child);
169895
- if (alias && path12 && importWildcard(child) === "none")
169896
- aliasMap.set(alias, path12);
169916
+ const path10 = importedPath(child);
169917
+ if (alias && path10 && importWildcard(child) === "none")
169918
+ aliasMap.set(alias, path10);
169897
169919
  } else if (isVerifyStmt(child))
169898
169920
  verifyStmts.push(child);
169899
169921
  else if (isSatisfyStmt(child))
@@ -170368,16 +170390,16 @@ ${baseIndent}}`;
170368
170390
  // REQ-320 — RES004 importing a private element from outside its namespace
170369
170391
  checkPrivateImports(imports, index2, accept) {
170370
170392
  for (const imp of imports) {
170371
- const path12 = importedPath(imp);
170372
- if (!path12)
170393
+ const path10 = importedPath(imp);
170394
+ if (!path10)
170373
170395
  continue;
170374
- const target = this.resolve(path12, index2, imp);
170396
+ const target = this.resolve(path10, index2, imp);
170375
170397
  if (!target || !isPrivate(target))
170376
170398
  continue;
170377
170399
  if (isWithinNamespaceOf(imp, target))
170378
170400
  continue;
170379
- const related = relatedInfo(target, `'${declName(target) ?? path12}' is declared private here`);
170380
- accept(severity("RES004", "error"), `'${path12}' is private and cannot be imported from outside its namespace.`, { node: imp, code: "RES004", relatedInformation: related ? [related] : void 0 });
170401
+ const related = relatedInfo(target, `'${declName(target) ?? path10}' is declared private here`);
170402
+ accept(severity("RES004", "error"), `'${path10}' is private and cannot be imported from outside its namespace.`, { node: imp, code: "RES004", relatedInformation: related ? [related] : void 0 });
170381
170403
  }
170382
170404
  }
170383
170405
  // REQ-320 — RES004 for wildcard imports. `import Lib::*` legitimately skips
@@ -170394,9 +170416,9 @@ ${baseIndent}}`;
170394
170416
  const kind = importWildcard(imp);
170395
170417
  if (kind === "none")
170396
170418
  continue;
170397
- const path12 = importedPath(imp);
170398
- if (path12)
170399
- wildcards.push({ path: path12, recursive: kind === "recursive" });
170419
+ const path10 = importedPath(imp);
170420
+ if (path10)
170421
+ wildcards.push({ path: path10, recursive: kind === "recursive" });
170400
170422
  }
170401
170423
  if (wildcards.length === 0)
170402
170424
  return;
@@ -170461,10 +170483,10 @@ ${baseIndent}}`;
170461
170483
  // wildcard import (`import B::*` → `B`), or the owner of the named member for
170462
170484
  // a membership import (`import B::Member` → `B`). Resolved to its Package node.
170463
170485
  importTargetNamespace(imp, index2) {
170464
- const path12 = importedPath(imp);
170465
- if (!path12)
170486
+ const path10 = importedPath(imp);
170487
+ if (!path10)
170466
170488
  return void 0;
170467
- const nsName = importWildcard(imp) === "none" ? path12.includes("::") ? path12.slice(0, path12.lastIndexOf("::")) : void 0 : path12;
170489
+ const nsName = importWildcard(imp) === "none" ? path10.includes("::") ? path10.slice(0, path10.lastIndexOf("::")) : void 0 : path10;
170468
170490
  if (!nsName)
170469
170491
  return void 0;
170470
170492
  const node = this.resolve(nsName, index2, imp);
@@ -170493,9 +170515,9 @@ ${baseIndent}}`;
170493
170515
  for (const imp of imports) {
170494
170516
  if (importIsUsed(imp, index2, usedFull, usedFirst, this.nodeOf.bind(this)))
170495
170517
  continue;
170496
- const path12 = importedPath(imp) ?? imp.head;
170518
+ const path10 = importedPath(imp) ?? imp.head;
170497
170519
  const baseSeverity = level === "error" ? "error" : "warning";
170498
- accept(severity("RES009", baseSeverity), `Import '${path12}' is never used in this file.`, { node: imp, code: "RES009", tags: [import_vscode_languageserver16.DiagnosticTag.Unnecessary] });
170520
+ accept(severity("RES009", baseSeverity), `Import '${path10}' is never used in this file.`, { node: imp, code: "RES009", tags: [import_vscode_languageserver16.DiagnosticTag.Unnecessary] });
170499
170521
  }
170500
170522
  }
170501
170523
  // REQ-319 — RES003 cyclic specialization (warning)
@@ -171011,11 +171033,11 @@ function isClassifierNode(node) {
171011
171033
  return node.isDef === true || CLASSIFIER_TYPES.has(node.$type);
171012
171034
  }
171013
171035
  function hasAncestorType(node, type) {
171014
- let current = node.$container;
171015
- while (current) {
171016
- if (current.$type === type)
171036
+ let current2 = node.$container;
171037
+ while (current2) {
171038
+ if (current2.$type === type)
171017
171039
  return true;
171018
- current = current.$container;
171040
+ current2 = current2.$container;
171019
171041
  }
171020
171042
  return false;
171021
171043
  }
@@ -171185,17 +171207,17 @@ function collectUsedNames(root4) {
171185
171207
  return { usedFull, usedFirst };
171186
171208
  }
171187
171209
  function importIsUsed(imp, index2, usedFull, usedFirst, nodeOf) {
171188
- const path12 = importedPath(imp);
171189
- if (!path12)
171210
+ const path10 = importedPath(imp);
171211
+ if (!path10)
171190
171212
  return true;
171191
171213
  const wildcard = importWildcard(imp);
171192
- const prefix = path12 + "::";
171214
+ const prefix = path10 + "::";
171193
171215
  for (const ref of usedFull) {
171194
- if (ref === path12 || ref.startsWith(prefix))
171216
+ if (ref === path10 || ref.startsWith(prefix))
171195
171217
  return true;
171196
171218
  }
171197
171219
  if (wildcard === "none") {
171198
- const named2 = path12.split("::");
171220
+ const named2 = path10.split("::");
171199
171221
  const simple = imp.alias ?? named2[named2.length - 1];
171200
171222
  return usedFirst.has(simple);
171201
171223
  }
@@ -171639,9 +171661,9 @@ var SysmlScopeComputation = class extends DefaultScopeComputation {
171639
171661
  combineSegments(segmentChoices, separator) {
171640
171662
  let paths = [""];
171641
171663
  for (const choices of segmentChoices) {
171642
- paths = paths.flatMap((path12) => choices.map((choice) => path12 ? `${path12}${separator}${choice}` : choice));
171664
+ paths = paths.flatMap((path10) => choices.map((choice) => path10 ? `${path10}${separator}${choice}` : choice));
171643
171665
  }
171644
- return paths.filter((path12) => path12.length > 0);
171666
+ return paths.filter((path10) => path10.length > 0);
171645
171667
  }
171646
171668
  nameAliasesOf(node) {
171647
171669
  const aliases = [];
@@ -171695,17 +171717,17 @@ function exportAliasKey(description) {
171695
171717
  return `${description.name}|${description.documentUri.toString()}|${description.path}`;
171696
171718
  }
171697
171719
  function directImportEntries(imp, descriptions) {
171698
- const path12 = importedPath(imp);
171699
- if (!path12)
171720
+ const path10 = importedPath(imp);
171721
+ if (!path10)
171700
171722
  return [];
171701
171723
  const wildcard = importWildcard(imp);
171702
171724
  if (wildcard === "none") {
171703
- const description = descriptions.find((candidate) => candidate.name === path12);
171725
+ const description = descriptions.find((candidate) => candidate.name === path10);
171704
171726
  if (!description)
171705
171727
  return [];
171706
- return [{ name: imp.alias ?? path12.split("::").pop() ?? path12, description }];
171728
+ return [{ name: imp.alias ?? path10.split("::").pop() ?? path10, description }];
171707
171729
  }
171708
- const prefix = `${path12}::`;
171730
+ const prefix = `${path10}::`;
171709
171731
  const entries = [];
171710
171732
  const seen = /* @__PURE__ */ new Set();
171711
171733
  for (const description of descriptions) {
@@ -171741,7 +171763,6 @@ function specializationTargets5(node) {
171741
171763
  }
171742
171764
 
171743
171765
  // ../language-server/out/src/services/linker.js
171744
- import * as fs2 from "fs";
171745
171766
  var SysmlLinker = class extends DefaultLinker {
171746
171767
  documentFactory;
171747
171768
  libraryDocs = /* @__PURE__ */ new Map();
@@ -171771,15 +171792,15 @@ var SysmlLinker = class extends DefaultLinker {
171771
171792
  this.libraryDocs.set(key, live);
171772
171793
  return live;
171773
171794
  }
171774
- try {
171775
- const text = fs2.readFileSync(uri.fsPath, "utf8");
171776
- const doc = this.documentFactory.fromString(text, uri);
171777
- doc.isLibraryDocument = true;
171778
- this.libraryDocs.set(key, doc);
171779
- return doc;
171780
- } catch {
171795
+ if (!hasPlatform())
171781
171796
  return void 0;
171782
- }
171797
+ const text = getPlatform().readLibrarySourceSync(uri);
171798
+ if (text === void 0)
171799
+ return void 0;
171800
+ const doc = this.documentFactory.fromString(text, uri);
171801
+ doc.isLibraryDocument = true;
171802
+ this.libraryDocs.set(key, doc);
171803
+ return doc;
171783
171804
  }
171784
171805
  };
171785
171806
 
@@ -172224,14 +172245,14 @@ ${indent}}`)]
172224
172245
  }
172225
172246
  const importNode = nearestAncestor2(rangeNode, isImport);
172226
172247
  if (importNode?.$cstNode && importNode.alias && importNode.segs.every((s) => !s.star && s.name)) {
172227
- const path12 = [importNode.head, ...importNode.segs.map((s) => s.name)].join("::");
172248
+ const path10 = [importNode.head, ...importNode.segs.map((s) => s.name)].join("::");
172228
172249
  const prefix = importNode.visibility ? `${importNode.visibility} ` : "";
172229
172250
  actions.push({
172230
- title: `Convert to 'alias ${importNode.alias} for ${path12}'`,
172251
+ title: `Convert to 'alias ${importNode.alias} for ${path10}'`,
172231
172252
  kind: import_vscode_languageserver18.CodeActionKind.RefactorRewrite,
172232
172253
  edit: {
172233
172254
  changes: {
172234
- [uri]: [import_vscode_languageserver18.TextEdit.replace(importNode.$cstNode.range, `${prefix}alias ${importNode.alias} for ${path12};`)]
172255
+ [uri]: [import_vscode_languageserver18.TextEdit.replace(importNode.$cstNode.range, `${prefix}alias ${importNode.alias} for ${path10};`)]
172235
172256
  }
172236
172257
  }
172237
172258
  });
@@ -172862,10 +172883,10 @@ function indexByName(root4, type) {
172862
172883
  });
172863
172884
  return map3;
172864
172885
  }
172865
- function lastSegment3(path12) {
172866
- if (!path12)
172886
+ function lastSegment3(path10) {
172887
+ if (!path10)
172867
172888
  return void 0;
172868
- return path12.split(/::|\./).pop();
172889
+ return path10.split(/::|\./).pop();
172869
172890
  }
172870
172891
  function qualifiedNameOf2(node) {
172871
172892
  const parts = [];
@@ -173559,8 +173580,6 @@ function normalizeDiagnosticCode(diagnostic) {
173559
173580
 
173560
173581
  // ../language-server/out/src/services/workspace-manager.js
173561
173582
  var import_vscode_languageserver26 = __toESM(require_main4(), 1);
173562
- import * as fs3 from "fs/promises";
173563
- import * as path2 from "path";
173564
173583
  var PROJECT_FILE_EXTENSIONS = /* @__PURE__ */ new Map([
173565
173584
  [".kpar", "kpar"],
173566
173585
  [".sysml", "source"],
@@ -173588,7 +173607,7 @@ var SysmlWorkspaceManager = class extends DefaultWorkspaceManager {
173588
173607
  this.folders = folders;
173589
173608
  this.projectInfo.clear();
173590
173609
  for (const folder of folders) {
173591
- this.projectInfo.set(folder.uri, await detectSysmlProjectFolder(folder, cancelToken));
173610
+ this.projectInfo.set(folder.uri, await detectSysmlProjectFolder(folder, this.fileSystemProvider, cancelToken));
173592
173611
  }
173593
173612
  if (cancelToken.isCancellationRequested) {
173594
173613
  return;
@@ -173615,12 +173634,12 @@ var SysmlWorkspaceManager = class extends DefaultWorkspaceManager {
173615
173634
  return [...this.projectInfo.values()];
173616
173635
  }
173617
173636
  };
173618
- async function detectSysmlProjectFolder(workspaceFolder, cancelToken = import_vscode_languageserver26.CancellationToken.None) {
173637
+ async function detectSysmlProjectFolder(workspaceFolder, fileSystem, cancelToken = import_vscode_languageserver26.CancellationToken.None) {
173619
173638
  const markers = [];
173620
173639
  let scanned = 0;
173621
173640
  let root4;
173622
173641
  try {
173623
- root4 = URI2.parse(workspaceFolder.uri).fsPath;
173642
+ root4 = URI2.parse(workspaceFolder.uri);
173624
173643
  } catch {
173625
173644
  return { workspaceFolder, isSysmlProject: false, markers };
173626
173645
  }
@@ -173630,28 +173649,24 @@ async function detectSysmlProjectFolder(workspaceFolder, cancelToken = import_vs
173630
173649
  }
173631
173650
  let entries;
173632
173651
  try {
173633
- entries = await fs3.readdir(directory, { withFileTypes: true });
173652
+ entries = await fileSystem.readDirectory(directory);
173634
173653
  } catch {
173635
173654
  return false;
173636
173655
  }
173637
173656
  scanned += entries.length;
173638
173657
  for (const entry of entries) {
173639
- if (!entry.isFile())
173658
+ if (!entry.isFile)
173640
173659
  continue;
173641
- const name = entry.name.toLowerCase();
173642
- const kind = PROJECT_FILE_EXTENSIONS.get(path2.extname(name));
173660
+ const kind = PROJECT_FILE_EXTENSIONS.get(extensionOf(UriUtils.basename(entry.uri)));
173643
173661
  if (!kind)
173644
173662
  continue;
173645
- markers.push({
173646
- kind,
173647
- path: path2.relative(root4, path2.join(directory, entry.name)).replace(/\\/g, "/")
173648
- });
173663
+ markers.push({ kind, path: UriUtils.relative(root4, entry.uri) });
173649
173664
  return true;
173650
173665
  }
173651
173666
  for (const entry of entries) {
173652
- if (!entry.isDirectory() || SKIPPED_PROJECT_SCAN_DIRS.has(entry.name))
173667
+ if (!entry.isDirectory || SKIPPED_PROJECT_SCAN_DIRS.has(UriUtils.basename(entry.uri)))
173653
173668
  continue;
173654
- if (await scanDirectory(path2.join(directory, entry.name)))
173669
+ if (await scanDirectory(entry.uri))
173655
173670
  return true;
173656
173671
  }
173657
173672
  return false;
@@ -173663,6 +173678,11 @@ async function detectSysmlProjectFolder(workspaceFolder, cancelToken = import_vs
173663
173678
  markers
173664
173679
  };
173665
173680
  }
173681
+ function extensionOf(name) {
173682
+ const lower2 = name.toLowerCase();
173683
+ const dot = lower2.lastIndexOf(".");
173684
+ return dot > 0 ? lower2.slice(dot) : "";
173685
+ }
173666
173686
 
173667
173687
  // ../language-server/out/src/services/value-converter.js
173668
173688
  var SysmlValueConverter = class extends DefaultValueConverter {
@@ -173775,17 +173795,134 @@ function createSysMLServices(context) {
173775
173795
  }
173776
173796
 
173777
173797
  // ../language-server/out/src/services/library-loader.js
173778
- import * as path5 from "path";
173779
- import * as fs5 from "fs";
173798
+ var INDEXING_STATUS_NOTIFICATION = "sysml/indexingStatus";
173799
+ var LIBRARY_LOAD_BATCH_SIZE = 8;
173800
+ var LibraryLoader = class {
173801
+ shared;
173802
+ constructor(shared) {
173803
+ this.shared = shared;
173804
+ }
173805
+ // REQ-002, REQ-003, REQ-009, REQ-075, REQ-077, REQ-082, REQ-086, REQ-251 — Index bundled/configured SysML and KerML library files
173806
+ async loadLibrary(userLibraryPath) {
173807
+ const connection = this.shared.lsp.Connection;
173808
+ const platform = getPlatform();
173809
+ const resolved = await platform.resolveLibraryRoot(userLibraryPath);
173810
+ if (!resolved) {
173811
+ this.notify({ state: "ready", fileCount: 0, phase: "library" });
173812
+ return 0;
173813
+ }
173814
+ const libRoot = resolved.uri;
173815
+ registerLibraryRoot(libRoot);
173816
+ if (resolved.bundled) {
173817
+ const precomputed = await this.loadBundledPrecomputedIndex(libRoot);
173818
+ if (precomputed !== void 0) {
173819
+ connection?.console.log(`SysML: Loaded ${precomputed} precomputed library symbols from ${libRoot.toString()}`);
173820
+ this.notify({
173821
+ state: "ready",
173822
+ fileCount: precomputed,
173823
+ phase: "library",
173824
+ mode: "precomputed"
173825
+ });
173826
+ return precomputed;
173827
+ }
173828
+ connection?.console.warn("SysML: bundled standard-library index missing or unreadable; falling back to runtime indexing.");
173829
+ }
173830
+ const files = await platform.collectLibraryFiles(libRoot);
173831
+ if (files.length === 0) {
173832
+ this.notify({ state: "ready", fileCount: 0, totalFileCount: 0, phase: "library", mode: "runtime" });
173833
+ return 0;
173834
+ }
173835
+ this.notify({
173836
+ state: "indexing",
173837
+ fileCount: 0,
173838
+ totalFileCount: files.length,
173839
+ phase: "library",
173840
+ mode: "runtime"
173841
+ });
173842
+ let loaded = 0;
173843
+ const workspace = this.shared.workspace;
173844
+ const docs = [];
173845
+ for (let i = 0; i < files.length; i++) {
173846
+ const uri = files[i];
173847
+ try {
173848
+ const doc = await workspace.LangiumDocuments.getOrCreateDocument(uri);
173849
+ doc.isLibraryDocument = true;
173850
+ docs.push(doc);
173851
+ loaded++;
173852
+ } catch {
173853
+ }
173854
+ if ((i + 1) % LIBRARY_LOAD_BATCH_SIZE === 0 || i + 1 === files.length) {
173855
+ this.notify({
173856
+ state: "indexing",
173857
+ fileCount: loaded,
173858
+ totalFileCount: files.length,
173859
+ phase: "library",
173860
+ mode: "runtime"
173861
+ });
173862
+ await this.yieldToEventLoop();
173863
+ }
173864
+ }
173865
+ if (docs.length > 0) {
173866
+ await workspace.DocumentBuilder.build(docs, { validation: false });
173867
+ }
173868
+ connection?.console.log(`SysML: Loaded ${loaded} library files from ${libRoot.toString()}`);
173869
+ this.notify({
173870
+ state: "ready",
173871
+ fileCount: loaded,
173872
+ totalFileCount: files.length,
173873
+ phase: "library",
173874
+ mode: "runtime"
173875
+ });
173876
+ return loaded;
173877
+ }
173878
+ // REQ-075, REQ-383 — Load the precomputed symbol index shipped beside the
173879
+ // bundled library, then make that library's SOURCE readable synchronously so
173880
+ // the linker can resolve an index description on demand (see
173881
+ // `SysmlPlatform.primeLibrarySources`). Priming is driven by the file list in
173882
+ // the index we just parsed, so the 8 MB document is never read twice.
173883
+ async loadBundledPrecomputedIndex(libraryRoot) {
173884
+ const platform = getPlatform();
173885
+ const raw = await platform.readResource("sysml.library.index.json");
173886
+ if (raw === void 0)
173887
+ return void 0;
173888
+ const indexManager = this.shared.workspace.IndexManager;
173889
+ if (!isSysmlIndexManager(indexManager))
173890
+ return void 0;
173891
+ try {
173892
+ const index2 = JSON.parse(raw);
173893
+ if (index2.version !== 1)
173894
+ return void 0;
173895
+ const symbolCount = indexManager.loadPrecomputedLibraryIndex(index2, libraryRoot);
173896
+ await platform.primeLibrarySources(libraryRoot, index2.files.map((file) => file.path));
173897
+ return symbolCount;
173898
+ } catch (err) {
173899
+ this.shared.lsp.Connection?.console.warn(`SysML: failed to load precomputed library index: ${String(err)}`);
173900
+ return void 0;
173901
+ }
173902
+ }
173903
+ notify(status) {
173904
+ this.shared.lsp.Connection?.sendNotification(INDEXING_STATUS_NOTIFICATION, status);
173905
+ }
173906
+ // REQ-383 — Yield so the indexing-progress notifications actually reach the
173907
+ // client mid-load. `setImmediate` does not exist in a Web Worker, so this
173908
+ // uses the portable macrotask hop both hosts have.
173909
+ yieldToEventLoop() {
173910
+ return new Promise((resolve8) => setTimeout(resolve8, 0));
173911
+ }
173912
+ };
173913
+
173914
+ // ../language-server/out/src/platform/node-platform.js
173915
+ import * as fs3 from "fs";
173916
+ import * as path3 from "path";
173780
173917
 
173781
173918
  // ../language-server/out/src/services/kpar.js
173782
- import * as fs4 from "fs";
173919
+ import * as fs2 from "fs";
173783
173920
  import * as os from "os";
173784
- import * as path4 from "path";
173921
+ import * as path2 from "path";
173785
173922
  import * as zlib from "zlib";
173786
173923
 
173787
173924
  // ../language-server/out/src/services/abstract-syntax.js
173788
- import * as path3 from "path";
173925
+ import * as path from "path";
173789
173926
  var RESERVED_WORDS = /* @__PURE__ */ new Set([
173790
173927
  "abstract",
173791
173928
  "action",
@@ -174165,7 +174302,7 @@ function forEachObject(value, cb, seen = /* @__PURE__ */ new Set()) {
174165
174302
  }
174166
174303
  }
174167
174304
  function abstractSyntaxProjectionPath(jsonPath) {
174168
- const ext = path3.extname(jsonPath);
174305
+ const ext = path.extname(jsonPath);
174169
174306
  return ext ? jsonPath.slice(0, -ext.length) + ".abstract.sysml" : `${jsonPath}.abstract.sysml`;
174170
174307
  }
174171
174308
 
@@ -174176,9 +174313,9 @@ function isKparFile(p) {
174176
174313
  }
174177
174314
  function isKparDir(p) {
174178
174315
  try {
174179
- if (!fs4.statSync(p).isDirectory())
174316
+ if (!fs2.statSync(p).isDirectory())
174180
174317
  return false;
174181
- return fs4.readdirSync(p).some((name) => name.toLowerCase().endsWith(".kpar"));
174318
+ return fs2.readdirSync(p).some((name) => name.toLowerCase().endsWith(".kpar"));
174182
174319
  } catch {
174183
174320
  return false;
174184
174321
  }
@@ -174255,7 +174392,7 @@ function decodeLocalEntry(buffer, localHeaderOffset, method, compressedSize, max
174255
174392
  return void 0;
174256
174393
  }
174257
174394
  function extractKparModelFiles(kparPath, destDir, options = {}) {
174258
- const buffer = fs4.readFileSync(kparPath);
174395
+ const buffer = fs2.readFileSync(kparPath);
174259
174396
  const entries = readZipEntries(buffer);
174260
174397
  const written = [];
174261
174398
  let textualCount = 0;
@@ -174278,7 +174415,7 @@ function extractKparModelFiles(kparPath, destDir, options = {}) {
174278
174415
  if (!lower2.endsWith(".json") || lower2.endsWith(".meta.json") || lower2.endsWith(".project.json"))
174279
174416
  continue;
174280
174417
  try {
174281
- const converted = abstractSyntaxJsonToSysml(entry.data.toString("utf8"), path4.basename(entry.name, path4.extname(entry.name)));
174418
+ const converted = abstractSyntaxJsonToSysml(entry.data.toString("utf8"), path2.basename(entry.name, path2.extname(entry.name)));
174282
174419
  if (converted.elementCount === 0)
174283
174420
  continue;
174284
174421
  const target = safeTargetPath(destDir, abstractSyntaxProjectionPath(entry.name));
@@ -174297,16 +174434,16 @@ function extractKparDistribution(distributionPath) {
174297
174434
  return extractKparDistributionFiles(distributionPath)?.root;
174298
174435
  }
174299
174436
  function extractKparDistributionFiles(distributionPath, destRoot, options = { jsonAbstractSyntax: "when-no-text" }) {
174300
- const archives = isKparFile(distributionPath) ? [distributionPath] : fs4.readdirSync(distributionPath).filter((name) => name.toLowerCase().endsWith(".kpar")).sort((a2, b) => a2.localeCompare(b)).map((name) => path4.join(distributionPath, name));
174437
+ const archives = isKparFile(distributionPath) ? [distributionPath] : fs2.readdirSync(distributionPath).filter((name) => name.toLowerCase().endsWith(".kpar")).sort((a2, b) => a2.localeCompare(b)).map((name) => path2.join(distributionPath, name));
174301
174438
  if (archives.length === 0)
174302
174439
  return void 0;
174303
- const root4 = destRoot ?? fs4.mkdtempSync(path4.join(os.tmpdir(), "sysml-kpar-"));
174304
- fs4.mkdirSync(root4, { recursive: true });
174440
+ const root4 = destRoot ?? fs2.mkdtempSync(path2.join(os.tmpdir(), "sysml-kpar-"));
174441
+ fs2.mkdirSync(root4, { recursive: true });
174305
174442
  const files = [];
174306
174443
  let textualCount = 0;
174307
174444
  let jsonCount = 0;
174308
174445
  for (const archive of archives) {
174309
- const sub = path4.join(root4, path4.basename(archive, path4.extname(archive)));
174446
+ const sub = path2.join(root4, path2.basename(archive, path2.extname(archive)));
174310
174447
  try {
174311
174448
  const extracted = extractKparModelFiles(archive, sub, {
174312
174449
  jsonAbstractSyntax: options.jsonAbstractSyntax ?? "when-no-text",
@@ -174321,7 +174458,7 @@ function extractKparDistributionFiles(distributionPath, destRoot, options = { js
174321
174458
  if (files.length === 0) {
174322
174459
  if (!destRoot) {
174323
174460
  try {
174324
- fs4.rmSync(root4, { recursive: true, force: true });
174461
+ fs2.rmSync(root4, { recursive: true, force: true });
174325
174462
  } catch {
174326
174463
  }
174327
174464
  }
@@ -174339,179 +174476,103 @@ function safeTargetPath(destDir, entryName) {
174339
174476
  const safe = entryName.replace(/\\/gu, "/").split("/").filter((seg) => seg && seg !== "." && seg !== "..");
174340
174477
  if (safe.length === 0)
174341
174478
  return void 0;
174342
- return path4.join(destDir, ...safe);
174479
+ return path2.join(destDir, ...safe);
174343
174480
  }
174344
174481
  function writeExtractedFile(target, data, readonly) {
174345
- fs4.mkdirSync(path4.dirname(target), { recursive: true });
174346
- fs4.writeFileSync(target, data);
174482
+ fs2.mkdirSync(path2.dirname(target), { recursive: true });
174483
+ fs2.writeFileSync(target, data);
174347
174484
  if (readonly) {
174348
174485
  try {
174349
- fs4.chmodSync(target, 292);
174486
+ fs2.chmodSync(target, 292);
174350
174487
  } catch {
174351
174488
  }
174352
174489
  }
174353
174490
  }
174354
174491
 
174355
- // ../language-server/out/src/services/library-loader.js
174356
- var INDEXING_STATUS_NOTIFICATION = "sysml/indexingStatus";
174357
- var LIBRARY_LOAD_BATCH_SIZE = 8;
174358
- var LibraryLoader = class {
174359
- shared;
174360
- constructor(shared) {
174361
- this.shared = shared;
174492
+ // ../language-server/out/src/platform/node-platform.js
174493
+ var NodePlatform = class {
174494
+ extensionRoot;
174495
+ constructor(extensionRoot) {
174496
+ this.extensionRoot = extensionRoot;
174362
174497
  }
174363
- // REQ-002, REQ-003, REQ-009, REQ-075, REQ-077, REQ-082, REQ-086, REQ-251 — Index bundled/configured SysML and KerML library files
174364
- async loadLibrary(extensionPath, userLibraryPath) {
174365
- const connection = this.shared.lsp.Connection;
174366
- const resolved = this.resolveLibraryPath(extensionPath, userLibraryPath);
174367
- if (!resolved) {
174368
- this.notify({ state: "ready", fileCount: 0, phase: "library" });
174369
- return 0;
174370
- }
174371
- const libPath = resolved.path;
174372
- registerLibraryRoot(libPath);
174373
- if (resolved.bundled) {
174374
- const precomputed = this.loadBundledPrecomputedIndex(extensionPath, libPath);
174375
- if (precomputed !== void 0) {
174376
- connection?.console.log(`SysML: Loaded ${precomputed} precomputed library symbols from ${libPath}`);
174377
- this.notify({
174378
- state: "ready",
174379
- fileCount: precomputed,
174380
- phase: "library",
174381
- mode: "precomputed"
174382
- });
174383
- return precomputed;
174384
- }
174385
- connection?.console.warn("SysML: bundled standard-library index missing or unreadable; falling back to runtime indexing.");
174386
- }
174387
- const files = this.collectLibraryFiles(libPath);
174388
- if (files.length === 0) {
174389
- this.notify({ state: "ready", fileCount: 0, totalFileCount: 0, phase: "library", mode: "runtime" });
174390
- return 0;
174391
- }
174392
- this.notify({
174393
- state: "indexing",
174394
- fileCount: 0,
174395
- totalFileCount: files.length,
174396
- phase: "library",
174397
- mode: "runtime"
174398
- });
174399
- let loaded = 0;
174400
- const workspace = this.shared.workspace;
174401
- const docs = [];
174402
- for (let i = 0; i < files.length; i++) {
174403
- const file = files[i];
174404
- try {
174405
- const uri = URI2.file(file);
174406
- const doc = await workspace.LangiumDocuments.getOrCreateDocument(uri);
174407
- doc.isLibraryDocument = true;
174408
- docs.push(doc);
174409
- loaded++;
174410
- } catch {
174411
- }
174412
- if ((i + 1) % LIBRARY_LOAD_BATCH_SIZE === 0 || i + 1 === files.length) {
174413
- this.notify({
174414
- state: "indexing",
174415
- fileCount: loaded,
174416
- totalFileCount: files.length,
174417
- phase: "library",
174418
- mode: "runtime"
174419
- });
174420
- await this.yieldToEventLoop();
174421
- }
174422
- }
174423
- if (docs.length > 0) {
174424
- await workspace.DocumentBuilder.build(docs, { validation: false });
174498
+ async readResource(relativePath) {
174499
+ try {
174500
+ const target = path3.join(this.extensionRoot, "resources", ...relativePath.split("/"));
174501
+ if (!fs3.existsSync(target))
174502
+ return void 0;
174503
+ return fs3.readFileSync(target, "utf8");
174504
+ } catch {
174505
+ return void 0;
174425
174506
  }
174426
- connection?.console.log(`SysML: Loaded ${loaded} library files from ${libPath}`);
174427
- this.notify({
174428
- state: "ready",
174429
- fileCount: loaded,
174430
- totalFileCount: files.length,
174431
- phase: "library",
174432
- mode: "runtime"
174433
- });
174434
- return loaded;
174435
174507
  }
174436
- // REQ-076, REQ-077, REQ-082, REQ-086, REQ-090 — Prefer the configured library
174437
- // path, fall back to the bundled library. When the configured path is a
174438
- // `.kpar` archive (or a directory of them, e.g. the OMG `sysml.library.kpar/`)
174439
- // rather than a source tree, extract its textual `.sysml`/`.kerml` source to a
174440
- // temp directory and route it into the SAME index path as the unzipped tree
174441
- // (REQ-090 constraint: no parallel loader). JSON-only `.kpar` abstract-syntax
174442
- // payloads are projected to textual source by REQ-354; XMI is not supported.
174443
- resolveLibraryPath(extensionPath, userPath) {
174444
- const bundled = path5.join(extensionPath, "resources", "sysml.library");
174445
- const connection = this.shared.lsp.Connection;
174446
- if (userPath && userPath.length > 0) {
174447
- const resolved = path5.resolve(userPath);
174448
- if (fs5.existsSync(resolved)) {
174508
+ // REQ-076, REQ-090 — Prefer the configured library path, fall back to the
174509
+ // bundled library. A configured `.kpar` archive (or a directory of them,
174510
+ // e.g. the OMG `sysml.library.kpar/` distribution) is extracted to a temp
174511
+ // directory and routed into the SAME index path as an unzipped tree, so
174512
+ // there is no parallel loader.
174513
+ async resolveLibraryRoot(userLibraryPath) {
174514
+ const bundled = path3.join(this.extensionRoot, "resources", "sysml.library");
174515
+ if (userLibraryPath && userLibraryPath.length > 0) {
174516
+ const resolved = path3.resolve(userLibraryPath);
174517
+ if (fs3.existsSync(resolved)) {
174449
174518
  if (classifyDistribution(resolved) === "kpar") {
174450
174519
  const extracted = extractKparDistribution(resolved);
174451
174520
  if (extracted) {
174452
- connection?.console.log(`SysML: extracted .kpar distribution '${resolved}' to '${extracted}'`);
174453
- return { path: extracted, bundled: false, format: "kpar" };
174521
+ return { uri: URI2.file(extracted), bundled: false, format: "kpar" };
174454
174522
  }
174455
- connection?.console.warn(`SysML: .kpar distribution '${resolved}' contained no .sysml/.kerml source or supported .json abstract-syntax payload (XMI is not supported).`);
174456
- return null;
174523
+ return void 0;
174457
174524
  }
174458
174525
  return {
174459
- path: resolved,
174460
- bundled: path5.resolve(resolved) === path5.resolve(bundled),
174526
+ uri: URI2.file(resolved),
174527
+ bundled: path3.resolve(resolved) === path3.resolve(bundled),
174461
174528
  format: "tree"
174462
174529
  };
174463
174530
  }
174464
174531
  }
174465
- if (fs5.existsSync(bundled))
174466
- return { path: bundled, bundled: true, format: "tree" };
174467
- return null;
174532
+ if (fs3.existsSync(bundled))
174533
+ return { uri: URI2.file(bundled), bundled: true, format: "tree" };
174534
+ return void 0;
174468
174535
  }
174469
- loadBundledPrecomputedIndex(extensionPath, libraryRoot) {
174470
- const indexPath = path5.join(extensionPath, "resources", "sysml.library.index.json");
174471
- if (!fs5.existsSync(indexPath))
174472
- return void 0;
174473
- const indexManager = this.shared.workspace.IndexManager;
174474
- if (!isSysmlIndexManager(indexManager))
174475
- return void 0;
174536
+ libraryUri(libraryRoot, relativePath) {
174537
+ return UriUtils.joinPath(libraryRoot, ...relativePath.split("/"));
174538
+ }
174539
+ // REQ-075 — Node reads library source on demand inside the linker, so there
174540
+ // is nothing to pre-load.
174541
+ async primeLibrarySources() {
174542
+ }
174543
+ readLibrarySourceSync(uri) {
174476
174544
  try {
174477
- const raw = fs5.readFileSync(indexPath, "utf8");
174478
- const index2 = JSON.parse(raw);
174479
- if (index2.version !== 1)
174480
- return void 0;
174481
- return indexManager.loadPrecomputedLibraryIndex(index2, libraryRoot);
174482
- } catch (err) {
174483
- this.shared.lsp.Connection?.console.warn(`SysML: failed to load precomputed library index: ${String(err)}`);
174545
+ return fs3.readFileSync(uri.fsPath, "utf8");
174546
+ } catch {
174484
174547
  return void 0;
174485
174548
  }
174486
174549
  }
174487
- // REQ-075, REQ-082, REQ-086 — Recursively collect SysML/KerML library source files
174488
- collectLibraryFiles(dir) {
174550
+ // REQ-075, REQ-082, REQ-086 — Recursively collect library source files.
174551
+ async collectLibraryFiles(libraryRoot) {
174489
174552
  const files = [];
174490
- try {
174491
- const entries = fs5.readdirSync(dir, { withFileTypes: true }).sort((a2, b) => a2.name.localeCompare(b.name));
174553
+ const walk = (dir) => {
174554
+ let entries;
174555
+ try {
174556
+ entries = fs3.readdirSync(dir, { withFileTypes: true }).sort((a2, b) => a2.name.localeCompare(b.name));
174557
+ } catch {
174558
+ return;
174559
+ }
174492
174560
  for (const entry of entries) {
174493
- const fullPath = path5.join(dir, entry.name);
174494
- if (entry.isDirectory()) {
174495
- files.push(...this.collectLibraryFiles(fullPath));
174496
- } else if (entry.name.endsWith(".sysml") || entry.name.endsWith(".kerml")) {
174497
- files.push(fullPath);
174498
- }
174561
+ const full = path3.join(dir, entry.name);
174562
+ if (entry.isDirectory())
174563
+ walk(full);
174564
+ else if (entry.name.endsWith(".sysml") || entry.name.endsWith(".kerml"))
174565
+ files.push(URI2.file(full));
174499
174566
  }
174500
- } catch {
174501
- }
174567
+ };
174568
+ walk(libraryRoot.fsPath);
174502
174569
  return files;
174503
174570
  }
174504
- notify(status) {
174505
- this.shared.lsp.Connection?.sendNotification(INDEXING_STATUS_NOTIFICATION, status);
174506
- }
174507
- yieldToEventLoop() {
174508
- return new Promise((resolve8) => setImmediate(resolve8));
174509
- }
174510
174571
  };
174511
174572
 
174512
174573
  // src/discovery.ts
174513
- import * as fs6 from "fs";
174514
- import * as path6 from "path";
174574
+ import * as fs4 from "fs";
174575
+ import * as path4 from "path";
174515
174576
  var MODEL_EXTENSIONS = [".sysml", ".kerml"];
174516
174577
  var SKIP_DIRECTORIES = /* @__PURE__ */ new Set([
174517
174578
  "node_modules",
@@ -174525,21 +174586,21 @@ var SKIP_DIRECTORIES = /* @__PURE__ */ new Set([
174525
174586
  ]);
174526
174587
  var MAX_INDEXED_FILES = 5e3;
174527
174588
  function isModelFile(file) {
174528
- return MODEL_EXTENSIONS.includes(path6.extname(file).toLowerCase());
174589
+ return MODEL_EXTENSIONS.includes(path4.extname(file).toLowerCase());
174529
174590
  }
174530
174591
  function walkModelFiles(dir, limit = Infinity) {
174531
174592
  const found = [];
174532
- const visit = (current) => {
174593
+ const visit = (current2) => {
174533
174594
  if (found.length >= limit) return;
174534
174595
  let entries;
174535
174596
  try {
174536
- entries = fs6.readdirSync(current, { withFileTypes: true });
174597
+ entries = fs4.readdirSync(current2, { withFileTypes: true });
174537
174598
  } catch {
174538
174599
  return;
174539
174600
  }
174540
174601
  for (const entry of entries.sort((a2, b) => a2.name.localeCompare(b.name))) {
174541
174602
  if (found.length >= limit) return;
174542
- const full = path6.join(current, entry.name);
174603
+ const full = path4.join(current2, entry.name);
174543
174604
  if (entry.isDirectory()) {
174544
174605
  if (!SKIP_DIRECTORIES.has(entry.name) && !entry.name.startsWith(".")) visit(full);
174545
174606
  continue;
@@ -174547,7 +174608,7 @@ function walkModelFiles(dir, limit = Infinity) {
174547
174608
  if (isModelFile(entry.name)) found.push(full);
174548
174609
  }
174549
174610
  };
174550
- visit(path6.resolve(dir));
174611
+ visit(path4.resolve(dir));
174551
174612
  return found;
174552
174613
  }
174553
174614
 
@@ -174568,11 +174629,11 @@ function diagnosticsOf(document2, file) {
174568
174629
  function resolveResourceRoot(fromDir) {
174569
174630
  const candidates = [
174570
174631
  fromDir,
174571
- path7.resolve(fromDir, ".."),
174572
- path7.resolve(fromDir, "..", "..", "extension"),
174573
- path7.resolve(fromDir, "..", "..", "..", "extension")
174632
+ path5.resolve(fromDir, ".."),
174633
+ path5.resolve(fromDir, "..", "..", "extension"),
174634
+ path5.resolve(fromDir, "..", "..", "..", "extension")
174574
174635
  ];
174575
- return candidates.find((dir) => fs7.existsSync(path7.join(dir, "resources", "sysml.library")));
174636
+ return candidates.find((dir) => fs5.existsSync(path5.join(dir, "resources", "sysml.library")));
174576
174637
  }
174577
174638
  async function bootServices(options) {
174578
174639
  const { shared } = createSysMLServices({ ...NodeFileSystem });
@@ -174580,11 +174641,12 @@ async function bootServices(options) {
174580
174641
  if (!resourceRoot && !options.library) {
174581
174642
  throw new Error("Standard library not found; pass --library <dir> or reinstall the package.");
174582
174643
  }
174583
- await new LibraryLoader(shared).loadLibrary(resourceRoot ?? "", options.library);
174644
+ setPlatform(new NodePlatform(resourceRoot ?? ""));
174645
+ await new LibraryLoader(shared).loadLibrary(options.library);
174584
174646
  loadDimensionTable(resourceRoot);
174585
174647
  await shared.workspace.WorkspaceManager.initializeWorkspace(
174586
174648
  options.workspaceFolders.map((folder) => ({
174587
- name: path7.basename(folder),
174649
+ name: path5.basename(folder),
174588
174650
  uri: URI2.file(folder).toString()
174589
174651
  }))
174590
174652
  );
@@ -174606,23 +174668,23 @@ async function bootServices(options) {
174606
174668
  return {
174607
174669
  shared,
174608
174670
  indexedFiles,
174609
- document: (file) => shared.workspace.LangiumDocuments.getOrCreateDocument(URI2.file(path7.resolve(file)))
174671
+ document: (file) => shared.workspace.LangiumDocuments.getOrCreateDocument(URI2.file(path5.resolve(file)))
174610
174672
  };
174611
174673
  }
174612
174674
  function loadDimensionTable(resourceRoot) {
174613
174675
  if (!resourceRoot) return;
174614
174676
  try {
174615
- const table2 = path7.join(resourceRoot, "resources", "sysml.dimension-table.json");
174616
- if (!fs7.existsSync(table2)) return;
174617
- const parsed = JSON.parse(fs7.readFileSync(table2, "utf8"));
174677
+ const table2 = path5.join(resourceRoot, "resources", "sysml.dimension-table.json");
174678
+ if (!fs5.existsSync(table2)) return;
174679
+ const parsed = JSON.parse(fs5.readFileSync(table2, "utf8"));
174618
174680
  if (parsed.version === 1) setDimensionTable(parsed);
174619
174681
  } catch {
174620
174682
  }
174621
174683
  }
174622
174684
 
174623
174685
  // src/workspace.ts
174624
- import * as fs8 from "fs";
174625
- import * as path8 from "path";
174686
+ import * as fs6 from "fs";
174687
+ import * as path6 from "path";
174626
174688
 
174627
174689
  // ../extension/src/diagram-project-config.ts
174628
174690
  function projectConfigRelPath() {
@@ -174666,14 +174728,14 @@ function resolveOverride(override, vscodeValue) {
174666
174728
 
174667
174729
  // src/workspace.ts
174668
174730
  function findWorkspaceRoot(target) {
174669
- const resolved = path8.resolve(target);
174670
- const start2 = fs8.existsSync(resolved) && fs8.statSync(resolved).isDirectory() ? resolved : path8.dirname(resolved);
174731
+ const resolved = path6.resolve(target);
174732
+ const start2 = fs6.existsSync(resolved) && fs6.statSync(resolved).isDirectory() ? resolved : path6.dirname(resolved);
174671
174733
  let repoRoot;
174672
174734
  let dir = start2;
174673
174735
  for (; ; ) {
174674
- if (fs8.existsSync(path8.join(dir, ".vscode", "sysml"))) return dir;
174675
- if (repoRoot === void 0 && fs8.existsSync(path8.join(dir, ".git"))) repoRoot = dir;
174676
- const parent = path8.dirname(dir);
174736
+ if (fs6.existsSync(path6.join(dir, ".vscode", "sysml"))) return dir;
174737
+ if (repoRoot === void 0 && fs6.existsSync(path6.join(dir, ".git"))) repoRoot = dir;
174738
+ const parent = path6.dirname(dir);
174677
174739
  if (parent === dir) break;
174678
174740
  dir = parent;
174679
174741
  }
@@ -174682,7 +174744,7 @@ function findWorkspaceRoot(target) {
174682
174744
  function readJsonFile(file) {
174683
174745
  let text;
174684
174746
  try {
174685
- text = fs8.readFileSync(file, "utf8");
174747
+ text = fs6.readFileSync(file, "utf8");
174686
174748
  } catch {
174687
174749
  return void 0;
174688
174750
  }
@@ -174726,7 +174788,7 @@ function stripJsonComments(text) {
174726
174788
  return out.replace(/,(\s*[}\]])/g, "$1");
174727
174789
  }
174728
174790
  function readProjectConfig(root4) {
174729
- const raw = readJsonFile(path8.join(root4, projectConfigRelPath()));
174791
+ const raw = readJsonFile(path6.join(root4, projectConfigRelPath()));
174730
174792
  return raw === void 0 ? void 0 : normalizeProjectConfig(raw);
174731
174793
  }
174732
174794
 
@@ -180339,12 +180401,12 @@ function getSmoothStepPath({ sourceX, sourceY, sourcePosition = Position3.Bottom
180339
180401
  offset,
180340
180402
  stepPosition
180341
180403
  });
180342
- let path12 = `M${points[0].x} ${points[0].y}`;
180404
+ let path10 = `M${points[0].x} ${points[0].y}`;
180343
180405
  for (let i = 1; i < points.length - 1; i++) {
180344
- path12 += getBend(points[i - 1], points[i], points[i + 1], borderRadius);
180406
+ path10 += getBend(points[i - 1], points[i], points[i + 1], borderRadius);
180345
180407
  }
180346
- path12 += `L${points[points.length - 1].x} ${points[points.length - 1].y}`;
180347
- return [path12, labelX, labelY, offsetX, offsetY];
180408
+ path10 += `L${points[points.length - 1].x} ${points[points.length - 1].y}`;
180409
+ return [path10, labelX, labelY, offsetX, offsetY];
180348
180410
  }
180349
180411
  function isNodeInitialized(node) {
180350
180412
  return node && !!(node.internals.handleBounds || node.handles?.length) && !!(node.measured.width || node.width || node.initialWidth);
@@ -180821,14 +180883,14 @@ function isParentSelected(node, nodeLookup) {
180821
180883
  return isParentSelected(parentNode, nodeLookup);
180822
180884
  }
180823
180885
  function hasSelector(target, selector, domNode) {
180824
- let current = target;
180886
+ let current2 = target;
180825
180887
  do {
180826
- if (current?.matches?.(selector))
180888
+ if (current2?.matches?.(selector))
180827
180889
  return true;
180828
- if (current === domNode)
180890
+ if (current2 === domNode)
180829
180891
  return false;
180830
- current = current?.parentElement;
180831
- } while (current);
180892
+ current2 = current2?.parentElement;
180893
+ } while (current2);
180832
180894
  return false;
180833
180895
  }
180834
180896
  function getDragItems(nodeLookup, nodesDraggable, mousePos, nodeId) {
@@ -184104,8 +184166,8 @@ function EdgeTextComponent({ x, y, label, labelStyle, labelShowBg = true, labelB
184104
184166
  }
184105
184167
  EdgeTextComponent.displayName = "EdgeText";
184106
184168
  var EdgeText = (0, import_react2.memo)(EdgeTextComponent);
184107
- function BaseEdge({ path: path12, labelX, labelY, label, labelStyle, labelShowBg, labelBgStyle, labelBgPadding, labelBgBorderRadius, interactionWidth = 20, ...props }) {
184108
- return (0, import_jsx_runtime.jsxs)(import_jsx_runtime.Fragment, { children: [(0, import_jsx_runtime.jsx)("path", { ...props, d: path12, fill: "none", className: cc2(["react-flow__edge-path", props.className]) }), interactionWidth ? (0, import_jsx_runtime.jsx)("path", { d: path12, fill: "none", strokeOpacity: 0, strokeWidth: interactionWidth, className: "react-flow__edge-interaction" }) : null, label && isNumeric(labelX) && isNumeric(labelY) ? (0, import_jsx_runtime.jsx)(EdgeText, { x: labelX, y: labelY, label, labelStyle, labelShowBg, labelBgStyle, labelBgPadding, labelBgBorderRadius }) : null] });
184169
+ function BaseEdge({ path: path10, labelX, labelY, label, labelStyle, labelShowBg, labelBgStyle, labelBgPadding, labelBgBorderRadius, interactionWidth = 20, ...props }) {
184170
+ return (0, import_jsx_runtime.jsxs)(import_jsx_runtime.Fragment, { children: [(0, import_jsx_runtime.jsx)("path", { ...props, d: path10, fill: "none", className: cc2(["react-flow__edge-path", props.className]) }), interactionWidth ? (0, import_jsx_runtime.jsx)("path", { d: path10, fill: "none", strokeOpacity: 0, strokeWidth: interactionWidth, className: "react-flow__edge-interaction" }) : null, label && isNumeric(labelX) && isNumeric(labelY) ? (0, import_jsx_runtime.jsx)(EdgeText, { x: labelX, y: labelY, label, labelStyle, labelShowBg, labelBgStyle, labelBgPadding, labelBgBorderRadius }) : null] });
184109
184171
  }
184110
184172
  function getControl({ pos, x1, y1, x2, y2 }) {
184111
184173
  if (pos === Position3.Left || pos === Position3.Right) {
@@ -184148,7 +184210,7 @@ function getSimpleBezierPath({ sourceX, sourceY, sourcePosition = Position3.Bott
184148
184210
  }
184149
184211
  function createSimpleBezierEdge(params) {
184150
184212
  return (0, import_react2.memo)(({ id: id2, sourceX, sourceY, targetX, targetY, sourcePosition, targetPosition, label, labelStyle, labelShowBg, labelBgStyle, labelBgPadding, labelBgBorderRadius, style: style2, markerEnd, markerStart, interactionWidth }) => {
184151
- const [path12, labelX, labelY] = getSimpleBezierPath({
184213
+ const [path10, labelX, labelY] = getSimpleBezierPath({
184152
184214
  sourceX,
184153
184215
  sourceY,
184154
184216
  sourcePosition,
@@ -184157,7 +184219,7 @@ function createSimpleBezierEdge(params) {
184157
184219
  targetPosition
184158
184220
  });
184159
184221
  const _id = params.isInternal ? void 0 : id2;
184160
- return (0, import_jsx_runtime.jsx)(BaseEdge, { id: _id, path: path12, labelX, labelY, label, labelStyle, labelShowBg, labelBgStyle, labelBgPadding, labelBgBorderRadius, style: style2, markerEnd, markerStart, interactionWidth });
184222
+ return (0, import_jsx_runtime.jsx)(BaseEdge, { id: _id, path: path10, labelX, labelY, label, labelStyle, labelShowBg, labelBgStyle, labelBgPadding, labelBgBorderRadius, style: style2, markerEnd, markerStart, interactionWidth });
184161
184223
  });
184162
184224
  }
184163
184225
  var SimpleBezierEdge = createSimpleBezierEdge({ isInternal: false });
@@ -184166,7 +184228,7 @@ SimpleBezierEdge.displayName = "SimpleBezierEdge";
184166
184228
  SimpleBezierEdgeInternal.displayName = "SimpleBezierEdgeInternal";
184167
184229
  function createSmoothStepEdge(params) {
184168
184230
  return (0, import_react2.memo)(({ id: id2, sourceX, sourceY, targetX, targetY, label, labelStyle, labelShowBg, labelBgStyle, labelBgPadding, labelBgBorderRadius, style: style2, sourcePosition = Position3.Bottom, targetPosition = Position3.Top, markerEnd, markerStart, pathOptions, interactionWidth }) => {
184169
- const [path12, labelX, labelY] = getSmoothStepPath({
184231
+ const [path10, labelX, labelY] = getSmoothStepPath({
184170
184232
  sourceX,
184171
184233
  sourceY,
184172
184234
  sourcePosition,
@@ -184178,7 +184240,7 @@ function createSmoothStepEdge(params) {
184178
184240
  stepPosition: pathOptions?.stepPosition
184179
184241
  });
184180
184242
  const _id = params.isInternal ? void 0 : id2;
184181
- return (0, import_jsx_runtime.jsx)(BaseEdge, { id: _id, path: path12, labelX, labelY, label, labelStyle, labelShowBg, labelBgStyle, labelBgPadding, labelBgBorderRadius, style: style2, markerEnd, markerStart, interactionWidth });
184243
+ return (0, import_jsx_runtime.jsx)(BaseEdge, { id: _id, path: path10, labelX, labelY, label, labelStyle, labelShowBg, labelBgStyle, labelBgPadding, labelBgBorderRadius, style: style2, markerEnd, markerStart, interactionWidth });
184182
184244
  });
184183
184245
  }
184184
184246
  var SmoothStepEdge = createSmoothStepEdge({ isInternal: false });
@@ -184197,9 +184259,9 @@ StepEdge.displayName = "StepEdge";
184197
184259
  StepEdgeInternal.displayName = "StepEdgeInternal";
184198
184260
  function createStraightEdge(params) {
184199
184261
  return (0, import_react2.memo)(({ id: id2, sourceX, sourceY, targetX, targetY, label, labelStyle, labelShowBg, labelBgStyle, labelBgPadding, labelBgBorderRadius, style: style2, markerEnd, markerStart, interactionWidth }) => {
184200
- const [path12, labelX, labelY] = getStraightPath({ sourceX, sourceY, targetX, targetY });
184262
+ const [path10, labelX, labelY] = getStraightPath({ sourceX, sourceY, targetX, targetY });
184201
184263
  const _id = params.isInternal ? void 0 : id2;
184202
- return (0, import_jsx_runtime.jsx)(BaseEdge, { id: _id, path: path12, labelX, labelY, label, labelStyle, labelShowBg, labelBgStyle, labelBgPadding, labelBgBorderRadius, style: style2, markerEnd, markerStart, interactionWidth });
184264
+ return (0, import_jsx_runtime.jsx)(BaseEdge, { id: _id, path: path10, labelX, labelY, label, labelStyle, labelShowBg, labelBgStyle, labelBgPadding, labelBgBorderRadius, style: style2, markerEnd, markerStart, interactionWidth });
184203
184265
  });
184204
184266
  }
184205
184267
  var StraightEdge = createStraightEdge({ isInternal: false });
@@ -184208,7 +184270,7 @@ StraightEdge.displayName = "StraightEdge";
184208
184270
  StraightEdgeInternal.displayName = "StraightEdgeInternal";
184209
184271
  function createBezierEdge(params) {
184210
184272
  return (0, import_react2.memo)(({ id: id2, sourceX, sourceY, targetX, targetY, sourcePosition = Position3.Bottom, targetPosition = Position3.Top, label, labelStyle, labelShowBg, labelBgStyle, labelBgPadding, labelBgBorderRadius, style: style2, markerEnd, markerStart, pathOptions, interactionWidth }) => {
184211
- const [path12, labelX, labelY] = getBezierPath({
184273
+ const [path10, labelX, labelY] = getBezierPath({
184212
184274
  sourceX,
184213
184275
  sourceY,
184214
184276
  sourcePosition,
@@ -184218,7 +184280,7 @@ function createBezierEdge(params) {
184218
184280
  curvature: pathOptions?.curvature
184219
184281
  });
184220
184282
  const _id = params.isInternal ? void 0 : id2;
184221
- return (0, import_jsx_runtime.jsx)(BaseEdge, { id: _id, path: path12, labelX, labelY, label, labelStyle, labelShowBg, labelBgStyle, labelBgPadding, labelBgBorderRadius, style: style2, markerEnd, markerStart, interactionWidth });
184283
+ return (0, import_jsx_runtime.jsx)(BaseEdge, { id: _id, path: path10, labelX, labelY, label, labelStyle, labelShowBg, labelBgStyle, labelBgPadding, labelBgBorderRadius, style: style2, markerEnd, markerStart, interactionWidth });
184222
184284
  });
184223
184285
  }
184224
184286
  var BezierEdge = createBezierEdge({ isInternal: false });
@@ -184502,7 +184564,7 @@ var ConnectionLine = ({ style: style2, type = ConnectionLineType.Bezier, CustomC
184502
184564
  if (CustomComponent) {
184503
184565
  return (0, import_jsx_runtime.jsx)(CustomComponent, { connectionLineType: type, connectionLineStyle: style2, fromNode, fromHandle, fromX: from.x, fromY: from.y, toX: to.x, toY: to.y, fromPosition, toPosition, connectionStatus: getConnectionStatus(isValid), toNode, toHandle, pointer });
184504
184566
  }
184505
- let path12 = "";
184567
+ let path10 = "";
184506
184568
  const pathParams = {
184507
184569
  sourceX: from.x,
184508
184570
  sourceY: from.y,
@@ -184513,24 +184575,24 @@ var ConnectionLine = ({ style: style2, type = ConnectionLineType.Bezier, CustomC
184513
184575
  };
184514
184576
  switch (type) {
184515
184577
  case ConnectionLineType.Bezier:
184516
- [path12] = getBezierPath(pathParams);
184578
+ [path10] = getBezierPath(pathParams);
184517
184579
  break;
184518
184580
  case ConnectionLineType.SimpleBezier:
184519
- [path12] = getSimpleBezierPath(pathParams);
184581
+ [path10] = getSimpleBezierPath(pathParams);
184520
184582
  break;
184521
184583
  case ConnectionLineType.Step:
184522
- [path12] = getSmoothStepPath({
184584
+ [path10] = getSmoothStepPath({
184523
184585
  ...pathParams,
184524
184586
  borderRadius: 0
184525
184587
  });
184526
184588
  break;
184527
184589
  case ConnectionLineType.SmoothStep:
184528
- [path12] = getSmoothStepPath(pathParams);
184590
+ [path10] = getSmoothStepPath(pathParams);
184529
184591
  break;
184530
184592
  default:
184531
- [path12] = getStraightPath(pathParams);
184593
+ [path10] = getStraightPath(pathParams);
184532
184594
  }
184533
- return (0, import_jsx_runtime.jsx)("path", { d: path12, fill: "none", className: "react-flow__connection-path", style: style2 });
184595
+ return (0, import_jsx_runtime.jsx)("path", { d: path10, fill: "none", className: "react-flow__connection-path", style: style2 });
184534
184596
  };
184535
184597
  ConnectionLine.displayName = "ConnectionLine";
184536
184598
  var emptyTypes = {};
@@ -185968,8 +186030,8 @@ function computeEdgePath(args) {
185968
186030
  }
185969
186031
  const sourcePosition = live?.sourcePosition ?? handleSide(sourceNode, edge.sourceHandle, byId, targetNode);
185970
186032
  const targetPosition = live?.targetPosition ?? handleSide(targetNode, edge.targetHandle, byId, sourceNode);
185971
- const [path12, labelX, labelY] = lineStyle === "straight" ? getStraightPath(common) : lineStyle === "curved" ? getBezierPath({ ...common, sourcePosition, targetPosition }) : getSmoothStepPath({ ...common, sourcePosition, targetPosition, borderRadius: 8 });
185972
- return { path: path12, label: { x: labelX, y: labelY }, source: sp, target: tp, anchors, normal: sd.normal };
186033
+ const [path10, labelX, labelY] = lineStyle === "straight" ? getStraightPath(common) : lineStyle === "curved" ? getBezierPath({ ...common, sourcePosition, targetPosition }) : getSmoothStepPath({ ...common, sourcePosition, targetPosition, borderRadius: 8 });
186034
+ return { path: path10, label: { x: labelX, y: labelY }, source: sp, target: tp, anchors, normal: sd.normal };
185973
186035
  }
185974
186036
 
185975
186037
  // ../extension/src/webview/diagram/flow/edge-style.ts
@@ -189016,7 +189078,7 @@ function renderNodeBody(node, lineStyle, index2) {
189016
189078
  }
189017
189079
 
189018
189080
  // src/config.ts
189019
- import * as path9 from "path";
189081
+ import * as path7 from "path";
189020
189082
  var MANIFEST_DEFAULTS = {
189021
189083
  defaultKind: "gv",
189022
189084
  showPortLabels: true,
@@ -189026,8 +189088,8 @@ var MANIFEST_DEFAULTS = {
189026
189088
  connectPointSpacing: CONNECT_POINT_SPACING_DEFAULT
189027
189089
  };
189028
189090
  function readSideCar(root4, file) {
189029
- const rel2 = path9.relative(root4, path9.resolve(file)).split(path9.sep).join("/");
189030
- const raw = readJsonFile(path9.join(root4, sidecarRelPath(rel2)));
189091
+ const rel2 = path7.relative(root4, path7.resolve(file)).split(path7.sep).join("/");
189092
+ const raw = readJsonFile(path7.join(root4, sidecarRelPath(rel2)));
189031
189093
  return raw === void 0 ? emptySideCar() : normalizeSideCar(raw);
189032
189094
  }
189033
189095
  function diagramSettingsFor(config) {
@@ -189160,21 +189222,21 @@ async function renderDiagramSvg(document2, provider, options) {
189160
189222
  });
189161
189223
  }
189162
189224
  function outputPathFor(command, kind) {
189163
- if (command.out) return path10.resolve(command.out);
189164
- const stem = path10.basename(command.file).replace(/\.(sysml|kerml)$/i, "");
189165
- return path10.resolve(command.outDir ?? ".", `${stem}.${kind}.${kind === "grv" ? "csv" : "svg"}`);
189225
+ if (command.out) return path8.resolve(command.out);
189226
+ const stem = path8.basename(command.file).replace(/\.(sysml|kerml)$/i, "");
189227
+ return path8.resolve(command.outDir ?? ".", `${stem}.${kind}.${kind === "grv" ? "csv" : "svg"}`);
189166
189228
  }
189167
189229
  async function runExport(command) {
189168
- const file = path10.resolve(command.file);
189169
- if (!fs9.existsSync(file)) throw new Error(`No such file: ${command.file}`);
189230
+ const file = path8.resolve(command.file);
189231
+ if (!fs7.existsSync(file)) throw new Error(`No such file: ${command.file}`);
189170
189232
  const services = await bootServices({
189171
- fromDir: path10.dirname(fileURLToPath(import.meta.url)),
189233
+ fromDir: path8.dirname(fileURLToPath(import.meta.url)),
189172
189234
  library: command.library,
189173
- workspaceFolders: [path10.dirname(file)]
189235
+ workspaceFolders: [path8.dirname(file)]
189174
189236
  });
189175
189237
  const document2 = await services.document(file);
189176
189238
  await services.shared.workspace.DocumentBuilder.build([document2], { validation: true });
189177
- const root4 = command.workspace ? path10.resolve(command.workspace) : findWorkspaceRoot(file);
189239
+ const root4 = command.workspace ? path8.resolve(command.workspace) : findWorkspaceRoot(file);
189178
189240
  const settings = diagramSettingsFor(readProjectConfig(root4));
189179
189241
  const sideCar = command.autoLayout ? emptySideCar() : readSideCar(root4, file);
189180
189242
  const provider = new SysmlDiagramModelProvider();
@@ -189197,18 +189259,18 @@ async function runExport(command) {
189197
189259
  continue;
189198
189260
  }
189199
189261
  const target = outputPathFor(command, kind);
189200
- fs9.mkdirSync(path10.dirname(target), { recursive: true });
189201
- fs9.writeFileSync(target, content, "utf8");
189262
+ fs7.mkdirSync(path8.dirname(target), { recursive: true });
189263
+ fs7.writeFileSync(target, content, "utf8");
189202
189264
  written.push(target);
189203
189265
  }
189204
189266
  return { written, diagnostics: diagnosticsOf(document2, file), empty: empty2 };
189205
189267
  }
189206
189268
 
189207
189269
  // src/main.ts
189208
- var VERSION2 = true ? "0.10.17" : "dev";
189270
+ var VERSION2 = true ? "0.11.0" : "dev";
189209
189271
  function display(file) {
189210
- const rel2 = path11.relative(process.cwd(), file);
189211
- return rel2 && !rel2.startsWith("..") ? rel2.split(path11.sep).join("/") : file;
189272
+ const rel2 = path9.relative(process.cwd(), file);
189273
+ return rel2 && !rel2.startsWith("..") ? rel2.split(path9.sep).join("/") : file;
189212
189274
  }
189213
189275
  function report(diagnostics) {
189214
189276
  for (const d of diagnostics) {
@@ -189254,12 +189316,12 @@ ${USAGE}`);
189254
189316
  const errors = result.diagnostics.filter((d) => d.severity === "error").length;
189255
189317
  const warnings = result.diagnostics.filter((d) => d.severity === "warning").length;
189256
189318
  if (errors > 0) {
189257
- process.stderr.write(`sysml-diagram: ${errors} error${errors === 1 ? "" : "s"} in ${display(path11.resolve(command.file))}.
189319
+ process.stderr.write(`sysml-diagram: ${errors} error${errors === 1 ? "" : "s"} in ${display(path9.resolve(command.file))}.
189258
189320
  `);
189259
189321
  return 1;
189260
189322
  }
189261
189323
  if (command.strict && warnings > 0) {
189262
- process.stderr.write(`sysml-diagram: ${warnings} warning${warnings === 1 ? "" : "s"} in ${display(path11.resolve(command.file))} (--strict).
189324
+ process.stderr.write(`sysml-diagram: ${warnings} warning${warnings === 1 ? "" : "s"} in ${display(path9.resolve(command.file))} (--strict).
189263
189325
  `);
189264
189326
  return 1;
189265
189327
  }
@@ -189271,7 +189333,7 @@ function isEntryPoint() {
189271
189333
  if (entry === void 0) return false;
189272
189334
  const here = fileURLToPath2(import.meta.url);
189273
189335
  try {
189274
- return fs10.realpathSync(entry) === fs10.realpathSync(here);
189336
+ return fs8.realpathSync(entry) === fs8.realpathSync(here);
189275
189337
  } catch {
189276
189338
  return pathToFileURL(entry).href === import.meta.url;
189277
189339
  }