@trops/dash-core 0.1.449 → 0.1.451

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.esm.js CHANGED
@@ -9294,7 +9294,7 @@ hasPropertyDescriptors.hasArrayLengthDefineBug = function hasArrayLengthDefineBu
9294
9294
  var hasPropertyDescriptors_1 = hasPropertyDescriptors;
9295
9295
 
9296
9296
  var keys = objectKeys$2;
9297
- var hasSymbols$5 = typeof Symbol === 'function' && typeof Symbol('foo') === 'symbol';
9297
+ var hasSymbols$4 = typeof Symbol === 'function' && typeof Symbol('foo') === 'symbol';
9298
9298
 
9299
9299
  var toStr$4 = Object.prototype.toString;
9300
9300
  var concat = Array.prototype.concat;
@@ -9327,7 +9327,7 @@ var defineProperty$1 = function (object, name, value, predicate) {
9327
9327
  var defineProperties$1 = function (object, map) {
9328
9328
  var predicates = arguments.length > 2 ? arguments[2] : {};
9329
9329
  var props = keys(map);
9330
- if (hasSymbols$5) {
9330
+ if (hasSymbols$4) {
9331
9331
  props = concat.call(props, Object.getOwnPropertySymbols(map));
9332
9332
  }
9333
9333
  for (var i = 0; i < props.length; i += 1) {
@@ -9393,11 +9393,11 @@ var sign$1 = function sign(number) {
9393
9393
  };
9394
9394
 
9395
9395
  var shams$1;
9396
- var hasRequiredShams;
9396
+ var hasRequiredShams$1;
9397
9397
 
9398
- function requireShams () {
9399
- if (hasRequiredShams) return shams$1;
9400
- hasRequiredShams = 1;
9398
+ function requireShams$1 () {
9399
+ if (hasRequiredShams$1) return shams$1;
9400
+ hasRequiredShams$1 = 1;
9401
9401
 
9402
9402
  /** @type {import('./shams')} */
9403
9403
  /* eslint complexity: [2, 18], max-statements: [2, 33] */
@@ -9446,10 +9446,10 @@ function requireShams () {
9446
9446
  }
9447
9447
 
9448
9448
  var origSymbol = typeof Symbol !== 'undefined' && Symbol;
9449
- var hasSymbolSham = requireShams();
9449
+ var hasSymbolSham = requireShams$1();
9450
9450
 
9451
9451
  /** @type {import('.')} */
9452
- var hasSymbols$4 = function hasNativeSymbols() {
9452
+ var hasSymbols$3 = function hasNativeSymbols() {
9453
9453
  if (typeof origSymbol !== 'function') { return false; }
9454
9454
  if (typeof Symbol !== 'function') { return false; }
9455
9455
  if (typeof origSymbol('foo') !== 'symbol') { return false; }
@@ -9753,7 +9753,7 @@ var ThrowTypeError = $gOPD$1
9753
9753
  }())
9754
9754
  : throwTypeError;
9755
9755
 
9756
- var hasSymbols$3 = hasSymbols$4();
9756
+ var hasSymbols$2 = hasSymbols$3();
9757
9757
 
9758
9758
  var getProto$2 = getProto$3;
9759
9759
  var $ObjectGPO = requireObject_getPrototypeOf();
@@ -9771,7 +9771,7 @@ var INTRINSICS = {
9771
9771
  '%AggregateError%': typeof AggregateError === 'undefined' ? undefined$1 : AggregateError,
9772
9772
  '%Array%': Array,
9773
9773
  '%ArrayBuffer%': typeof ArrayBuffer === 'undefined' ? undefined$1 : ArrayBuffer,
9774
- '%ArrayIteratorPrototype%': hasSymbols$3 && getProto$2 ? getProto$2([][Symbol.iterator]()) : undefined$1,
9774
+ '%ArrayIteratorPrototype%': hasSymbols$2 && getProto$2 ? getProto$2([][Symbol.iterator]()) : undefined$1,
9775
9775
  '%AsyncFromSyncIteratorPrototype%': undefined$1,
9776
9776
  '%AsyncFunction%': needsEval,
9777
9777
  '%AsyncGenerator%': needsEval,
@@ -9802,10 +9802,10 @@ var INTRINSICS = {
9802
9802
  '%Int32Array%': typeof Int32Array === 'undefined' ? undefined$1 : Int32Array,
9803
9803
  '%isFinite%': isFinite,
9804
9804
  '%isNaN%': isNaN,
9805
- '%IteratorPrototype%': hasSymbols$3 && getProto$2 ? getProto$2(getProto$2([][Symbol.iterator]())) : undefined$1,
9805
+ '%IteratorPrototype%': hasSymbols$2 && getProto$2 ? getProto$2(getProto$2([][Symbol.iterator]())) : undefined$1,
9806
9806
  '%JSON%': typeof JSON === 'object' ? JSON : undefined$1,
9807
9807
  '%Map%': typeof Map === 'undefined' ? undefined$1 : Map,
9808
- '%MapIteratorPrototype%': typeof Map === 'undefined' || !hasSymbols$3 || !getProto$2 ? undefined$1 : getProto$2(new Map()[Symbol.iterator]()),
9808
+ '%MapIteratorPrototype%': typeof Map === 'undefined' || !hasSymbols$2 || !getProto$2 ? undefined$1 : getProto$2(new Map()[Symbol.iterator]()),
9809
9809
  '%Math%': Math,
9810
9810
  '%Number%': Number,
9811
9811
  '%Object%': $Object$2,
@@ -9819,11 +9819,11 @@ var INTRINSICS = {
9819
9819
  '%Reflect%': typeof Reflect === 'undefined' ? undefined$1 : Reflect,
9820
9820
  '%RegExp%': RegExp,
9821
9821
  '%Set%': typeof Set === 'undefined' ? undefined$1 : Set,
9822
- '%SetIteratorPrototype%': typeof Set === 'undefined' || !hasSymbols$3 || !getProto$2 ? undefined$1 : getProto$2(new Set()[Symbol.iterator]()),
9822
+ '%SetIteratorPrototype%': typeof Set === 'undefined' || !hasSymbols$2 || !getProto$2 ? undefined$1 : getProto$2(new Set()[Symbol.iterator]()),
9823
9823
  '%SharedArrayBuffer%': typeof SharedArrayBuffer === 'undefined' ? undefined$1 : SharedArrayBuffer,
9824
9824
  '%String%': String,
9825
- '%StringIteratorPrototype%': hasSymbols$3 && getProto$2 ? getProto$2(''[Symbol.iterator]()) : undefined$1,
9826
- '%Symbol%': hasSymbols$3 ? Symbol : undefined$1,
9825
+ '%StringIteratorPrototype%': hasSymbols$2 && getProto$2 ? getProto$2(''[Symbol.iterator]()) : undefined$1,
9826
+ '%Symbol%': hasSymbols$2 ? Symbol : undefined$1,
9827
9827
  '%SyntaxError%': $SyntaxError$1,
9828
9828
  '%ThrowTypeError%': ThrowTypeError,
9829
9829
  '%TypedArray%': TypedArray,
@@ -10176,12 +10176,12 @@ var callBound$i = function callBoundIntrinsic(name, allowMissing) {
10176
10176
 
10177
10177
  // modified from https://github.com/es-shims/es6-shim
10178
10178
  var objectKeys$1 = objectKeys$2;
10179
- var hasSymbols$2 = requireShams()();
10179
+ var hasSymbols$1 = requireShams$1()();
10180
10180
  var callBound$h = callBound$i;
10181
10181
  var $Object$1 = esObjectAtoms;
10182
10182
  var $push = callBound$h('Array.prototype.push');
10183
10183
  var $propIsEnumerable = callBound$h('Object.prototype.propertyIsEnumerable');
10184
- var originalGetSymbols = hasSymbols$2 ? $Object$1.getOwnPropertySymbols : null;
10184
+ var originalGetSymbols = hasSymbols$1 ? $Object$1.getOwnPropertySymbols : null;
10185
10185
 
10186
10186
  // eslint-disable-next-line no-unused-vars
10187
10187
  var implementation$8 = function assign(target, source1) {
@@ -10195,7 +10195,7 @@ var implementation$8 = function assign(target, source1) {
10195
10195
 
10196
10196
  // step 3.a.ii:
10197
10197
  var keys = objectKeys$1(from);
10198
- var getSymbols = hasSymbols$2 && ($Object$1.getOwnPropertySymbols || originalGetSymbols);
10198
+ var getSymbols = hasSymbols$1 && ($Object$1.getOwnPropertySymbols || originalGetSymbols);
10199
10199
  if (getSymbols) {
10200
10200
  var syms = getSymbols(from);
10201
10201
  for (var j = 0; j < syms.length; ++j) {
@@ -10492,14 +10492,23 @@ var regexp_prototype_flags = flagsBound;
10492
10492
 
10493
10493
  var esGetIterator = {exports: {}};
10494
10494
 
10495
- var hasSymbols$1 = requireShams();
10495
+ var shams;
10496
+ var hasRequiredShams;
10496
10497
 
10497
- /** @type {import('.')} */
10498
- var shams = function hasToStringTagShams() {
10499
- return hasSymbols$1() && !!Symbol.toStringTag;
10500
- };
10498
+ function requireShams () {
10499
+ if (hasRequiredShams) return shams;
10500
+ hasRequiredShams = 1;
10501
+
10502
+ var hasSymbols = requireShams$1();
10501
10503
 
10502
- var hasToStringTag$7 = shams();
10504
+ /** @type {import('.')} */
10505
+ shams = function hasToStringTagShams() {
10506
+ return hasSymbols() && !!Symbol.toStringTag;
10507
+ };
10508
+ return shams;
10509
+ }
10510
+
10511
+ var hasToStringTag$7 = requireShams()();
10503
10512
  var callBound$f = callBound$i;
10504
10513
 
10505
10514
  var $toString$7 = callBound$f('Object.prototype.toString');
@@ -11536,7 +11545,7 @@ var tryStringObject = function tryStringObject(value) {
11536
11545
  /** @type {(receiver: ThisParameterType<typeof Object.prototype.toString>, ...args: Parameters<typeof Object.prototype.toString>) => ReturnType<typeof Object.prototype.toString>} */
11537
11546
  var $toString$6 = callBound$c('Object.prototype.toString');
11538
11547
  var strClass = '[object String]';
11539
- var hasToStringTag$6 = shams();
11548
+ var hasToStringTag$6 = requireShams()();
11540
11549
 
11541
11550
  /** @type {import('.')} */
11542
11551
  var isString$2 = function isString(value) {
@@ -11652,7 +11661,7 @@ var isSet$2 = exported$1 || function isSet(x) {
11652
11661
  var isArguments$1 = isArguments$2;
11653
11662
  var getStopIterationIterator = stopIterationIterator;
11654
11663
 
11655
- if (hasSymbols$4() || requireShams()()) {
11664
+ if (hasSymbols$3() || requireShams$1()()) {
11656
11665
  var $iterator = Symbol.iterator;
11657
11666
  // Symbol is available natively or shammed
11658
11667
  // natively:
@@ -11941,7 +11950,7 @@ var tryDateObject = function tryDateGetDayCall(value) {
11941
11950
  /** @type {(value: unknown) => string} */
11942
11951
  var toStr$2 = callBound$9('Object.prototype.toString');
11943
11952
  var dateClass = '[object Date]';
11944
- var hasToStringTag$5 = shams();
11953
+ var hasToStringTag$5 = requireShams()();
11945
11954
 
11946
11955
  /** @type {import('.')} */
11947
11956
  var isDateObject = function isDateObject(value) {
@@ -11952,7 +11961,7 @@ var isDateObject = function isDateObject(value) {
11952
11961
  };
11953
11962
 
11954
11963
  var callBound$8 = callBound$i;
11955
- var hasToStringTag$4 = shams();
11964
+ var hasToStringTag$4 = requireShams()();
11956
11965
  var hasOwn = hasown;
11957
11966
  var gOPD$1 = gopd$1;
11958
11967
 
@@ -12057,7 +12066,7 @@ var tryNumberObject = function tryNumberObject(value) {
12057
12066
  };
12058
12067
  var $toString$3 = callBound$6('Object.prototype.toString');
12059
12068
  var numClass = '[object Number]';
12060
- var hasToStringTag$3 = shams();
12069
+ var hasToStringTag$3 = requireShams()();
12061
12070
 
12062
12071
  /** @type {import('.')} */
12063
12072
  var isNumberObject = function isNumberObject(value) {
@@ -12084,7 +12093,7 @@ var tryBooleanObject = function booleanBrandCheck(value) {
12084
12093
  }
12085
12094
  };
12086
12095
  var boolClass = '[object Boolean]';
12087
- var hasToStringTag$2 = shams();
12096
+ var hasToStringTag$2 = requireShams()();
12088
12097
 
12089
12098
  /** @type {import('.')} */
12090
12099
  var isBooleanObject = function isBoolean(value) {
@@ -12126,7 +12135,7 @@ function requireSafeRegexTest () {
12126
12135
 
12127
12136
  var callBound$4 = callBound$i;
12128
12137
  var $toString$1 = callBound$4('Object.prototype.toString');
12129
- var hasSymbols = hasSymbols$4();
12138
+ var hasSymbols = hasSymbols$3();
12130
12139
  var safeRegexTest = requireSafeRegexTest();
12131
12140
 
12132
12141
  if (hasSymbols) {
@@ -12572,7 +12581,7 @@ var gOPD = gopd$1;
12572
12581
  var getProto = getProto$3;
12573
12582
 
12574
12583
  var $toString = callBound$2('Object.prototype.toString');
12575
- var hasToStringTag = shams();
12584
+ var hasToStringTag = requireShams()();
12576
12585
 
12577
12586
  var g = typeof globalThis === 'undefined' ? commonjsGlobal : globalThis;
12578
12587
  var typedArrays = availableTypedArrays();
@@ -45939,13 +45948,20 @@ var McpCatalogDetail = function McpCatalogDetail(_ref) {
45939
45948
  // eslint-disable-next-line react-hooks/exhaustive-deps
45940
45949
  }, [dashApi]);
45941
45950
 
45942
- // Filter catalog by search
45951
+ // Filter catalog by search, then sort alphabetically by display name.
45952
+ // Built-in and known-external entries are interleaved alphabetically —
45953
+ // the per-card "external" badge keeps the source obvious without
45954
+ // needing a separate group header.
45943
45955
  var filteredCatalog = catalog.filter(function (server) {
45944
45956
  if (!searchQuery) return true;
45945
45957
  var q = searchQuery.toLowerCase();
45946
45958
  return server.name.toLowerCase().includes(q) || server.description.toLowerCase().includes(q) || (server.tags || []).some(function (tag) {
45947
45959
  return tag.toLowerCase().includes(q);
45948
45960
  });
45961
+ }).slice().sort(function (a, b) {
45962
+ return String(a.name || "").localeCompare(String(b.name || ""), undefined, {
45963
+ sensitivity: "base"
45964
+ });
45949
45965
  });
45950
45966
 
45951
45967
  // Dynamic wizard steps based on whether auth is needed
@@ -49214,6 +49230,15 @@ var PublishWidgetModal = function PublishWidgetModal(_ref) {
49214
49230
  _useState14 = _slicedToArray(_useState13, 2),
49215
49231
  packageInfo = _useState14[0],
49216
49232
  setPackageInfo = _useState14[1];
49233
+ // When the main-process pre-publish scan finds personal filesystem
49234
+ // paths in the package source, it returns `{ needsConfirmation: true,
49235
+ // personalPathFindings: [...] }` instead of publishing. We stash the
49236
+ // findings and surface a confirm-or-cancel panel; "Publish anyway"
49237
+ // retries with `confirmPersonalPaths: true`.
49238
+ var _useState15 = useState(null),
49239
+ _useState16 = _slicedToArray(_useState15, 2),
49240
+ personalPathFindings = _useState16[0],
49241
+ setPersonalPathFindings = _useState16[1];
49217
49242
 
49218
49243
  // Reset modal state on open
49219
49244
  useEffect(function () {
@@ -49224,6 +49249,7 @@ var PublishWidgetModal = function PublishWidgetModal(_ref) {
49224
49249
  setIsPublishing(false);
49225
49250
  setResult(null);
49226
49251
  setPackageInfo(null);
49252
+ setPersonalPathFindings(null);
49227
49253
  }, [isOpen]);
49228
49254
 
49229
49255
  // Inspect the package to get its metadata + component list
@@ -49391,10 +49417,18 @@ var PublishWidgetModal = function PublishWidgetModal(_ref) {
49391
49417
  }
49392
49418
  function _handlePublish() {
49393
49419
  _handlePublish = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee4() {
49394
- var options, packageId, res, _t3;
49420
+ var _ref4,
49421
+ _ref4$confirmPersonal,
49422
+ confirmPersonalPaths,
49423
+ options,
49424
+ packageId,
49425
+ res,
49426
+ _args4 = arguments,
49427
+ _t3;
49395
49428
  return _regeneratorRuntime.wrap(function (_context4) {
49396
49429
  while (1) switch (_context4.prev = _context4.next) {
49397
49430
  case 0:
49431
+ _ref4 = _args4.length > 0 && _args4[0] !== undefined ? _args4[0] : {}, _ref4$confirmPersonal = _ref4.confirmPersonalPaths, confirmPersonalPaths = _ref4$confirmPersonal === void 0 ? false : _ref4$confirmPersonal;
49398
49432
  if (widget) {
49399
49433
  _context4.next = 1;
49400
49434
  break;
@@ -49403,18 +49437,28 @@ var PublishWidgetModal = function PublishWidgetModal(_ref) {
49403
49437
  case 1:
49404
49438
  setIsPublishing(true);
49405
49439
  setResult(null);
49440
+ if (!confirmPersonalPaths) setPersonalPathFindings(null);
49406
49441
  _context4.prev = 2;
49407
- options = _objectSpread$k({
49442
+ options = _objectSpread$k(_objectSpread$k({
49408
49443
  visibility: visibility
49409
49444
  }, bump && bump !== "none" ? {
49410
49445
  bump: bump
49446
+ } : {}), confirmPersonalPaths ? {
49447
+ confirmPersonalPaths: true
49411
49448
  } : {});
49412
49449
  packageId = widget.packageId || widget.name;
49413
49450
  _context4.next = 3;
49414
49451
  return window.mainApi.registry.publishWidget(appId, packageId, options);
49415
49452
  case 3:
49416
49453
  res = _context4.sent;
49417
- setResult(res);
49454
+ // Main process asked us to confirm a privacy warning before it ships
49455
+ // the package. Stash the findings and render the confirm panel —
49456
+ // don't mark as a completed result.
49457
+ if (res !== null && res !== void 0 && res.needsConfirmation && (res === null || res === void 0 ? void 0 : res.reason) === "personal-paths") {
49458
+ setPersonalPathFindings(res.personalPathFindings || []);
49459
+ } else {
49460
+ setResult(res);
49461
+ }
49418
49462
  _context4.next = 5;
49419
49463
  break;
49420
49464
  case 4:
@@ -49436,6 +49480,14 @@ var PublishWidgetModal = function PublishWidgetModal(_ref) {
49436
49480
  }));
49437
49481
  return _handlePublish.apply(this, arguments);
49438
49482
  }
49483
+ function handleCancelPersonalPathsConfirm() {
49484
+ setPersonalPathFindings(null);
49485
+ }
49486
+ function handleConfirmPersonalPathsAndPublish() {
49487
+ handlePublish({
49488
+ confirmPersonalPaths: true
49489
+ });
49490
+ }
49439
49491
  if (!widget) return null;
49440
49492
  var currentVersion = widget.version || "1.0.0";
49441
49493
  var newVersion = bumpPreview(currentVersion, bump);
@@ -49480,7 +49532,48 @@ var PublishWidgetModal = function PublishWidgetModal(_ref) {
49480
49532
  className: "text-xs text-red-300",
49481
49533
  children: authError
49482
49534
  })]
49483
- }), authStatus === "authenticated" && !result && /*#__PURE__*/jsxs(Fragment, {
49535
+ }), authStatus === "authenticated" && personalPathFindings && !result && /*#__PURE__*/jsxs("div", {
49536
+ className: "space-y-3",
49537
+ children: [/*#__PURE__*/jsxs("div", {
49538
+ className: "p-3 bg-amber-900/20 border border-amber-700/40 rounded text-sm text-amber-200",
49539
+ children: [/*#__PURE__*/jsxs("div", {
49540
+ className: "font-semibold flex items-center gap-2 mb-1",
49541
+ children: [/*#__PURE__*/jsx(FontAwesomeIcon, {
49542
+ icon: "triangle-exclamation",
49543
+ className: "h-4 w-4"
49544
+ }), "Personal paths detected in this package"]
49545
+ }), /*#__PURE__*/jsxs("div", {
49546
+ className: "text-xs opacity-90",
49547
+ children: ["The following lines look like absolute paths on your machine. Publishing will include them. If any of these are your local filesystem, replace them with a tilde (e.g.", /*#__PURE__*/jsx("code", {
49548
+ className: "px-1 opacity-90",
49549
+ children: "~/pipeline"
49550
+ }), ") or a schema ", /*#__PURE__*/jsx("code", {
49551
+ className: "px-1 opacity-90",
49552
+ children: "defaultValue"
49553
+ }), " ", "before publishing."]
49554
+ })]
49555
+ }), /*#__PURE__*/jsx("div", {
49556
+ className: "bg-white/5 border border-white/10 rounded-lg divide-y divide-white/10 max-h-60 overflow-y-auto",
49557
+ children: personalPathFindings.map(function (f, idx) {
49558
+ return /*#__PURE__*/jsxs("div", {
49559
+ className: "px-3 py-2 text-xs",
49560
+ children: [/*#__PURE__*/jsxs("div", {
49561
+ className: "font-mono text-amber-200 truncate",
49562
+ children: [f.file, ":", f.line]
49563
+ }), /*#__PURE__*/jsx("div", {
49564
+ className: "font-mono opacity-80 mt-0.5 break-all",
49565
+ children: f.match
49566
+ }), f.context && f.context !== f.match && /*#__PURE__*/jsx("div", {
49567
+ className: "font-mono opacity-50 mt-0.5 truncate",
49568
+ children: f.context
49569
+ })]
49570
+ }, "".concat(f.file, ":").concat(f.line, ":").concat(idx));
49571
+ })
49572
+ }), /*#__PURE__*/jsxs("div", {
49573
+ className: "text-xs opacity-60",
49574
+ children: ["Total findings: ", personalPathFindings.length, personalPathFindings.length >= 50 && " (capped)"]
49575
+ })]
49576
+ }), authStatus === "authenticated" && !result && !personalPathFindings && /*#__PURE__*/jsxs(Fragment, {
49484
49577
  children: [/*#__PURE__*/jsxs("div", {
49485
49578
  className: "bg-white/5 border border-white/10 rounded-lg p-3 text-sm",
49486
49579
  children: [/*#__PURE__*/jsxs("div", {
@@ -49641,16 +49734,29 @@ var PublishWidgetModal = function PublishWidgetModal(_ref) {
49641
49734
  })
49642
49735
  })]
49643
49736
  })]
49644
- }), /*#__PURE__*/jsxs("div", {
49737
+ }), /*#__PURE__*/jsx("div", {
49645
49738
  className: "flex-shrink-0 flex flex-row justify-end gap-2 p-4 border-t border-white/10",
49646
- children: [/*#__PURE__*/jsx(Button3, {
49647
- title: result !== null && result !== void 0 && result.success ? "Close" : "Cancel",
49648
- onClick: handleClose
49649
- }), !(result !== null && result !== void 0 && result.success) && /*#__PURE__*/jsx(Button2, {
49650
- title: isPublishing ? "Publishing…" : "Publish",
49651
- onClick: handlePublish,
49652
- disabled: !canPublish
49653
- })]
49739
+ children: personalPathFindings ? /*#__PURE__*/jsxs(Fragment, {
49740
+ children: [/*#__PURE__*/jsx(Button3, {
49741
+ title: "Go back",
49742
+ onClick: handleCancelPersonalPathsConfirm
49743
+ }), /*#__PURE__*/jsx(Button2, {
49744
+ title: isPublishing ? "Publishing…" : "Publish anyway",
49745
+ onClick: handleConfirmPersonalPathsAndPublish,
49746
+ disabled: isPublishing
49747
+ })]
49748
+ }) : /*#__PURE__*/jsxs(Fragment, {
49749
+ children: [/*#__PURE__*/jsx(Button3, {
49750
+ title: result !== null && result !== void 0 && result.success ? "Close" : "Cancel",
49751
+ onClick: handleClose
49752
+ }), !(result !== null && result !== void 0 && result.success) && /*#__PURE__*/jsx(Button2, {
49753
+ title: isPublishing ? "Publishing…" : "Publish",
49754
+ onClick: function onClick() {
49755
+ return handlePublish();
49756
+ },
49757
+ disabled: !canPublish
49758
+ })]
49759
+ })
49654
49760
  })]
49655
49761
  })
49656
49762
  });
@@ -62605,15 +62711,6 @@ function ChatCore(_ref) {
62605
62711
  }
62606
62712
  };
62607
62713
 
62608
- // End CLI session
62609
- var handleEndSession = function handleEndSession() {
62610
- var _mainApi$llm4;
62611
- if (!isCliBackend || !(mainApi !== null && mainApi !== void 0 && (_mainApi$llm4 = mainApi.llm) !== null && _mainApi$llm4 !== void 0 && _mainApi$llm4.endCliSession)) return;
62612
- if (isLoading) handleStop();
62613
- mainApi.llm.endCliSession(uuid || persistKey || sessionKey);
62614
- setSessionActive(false);
62615
- };
62616
-
62617
62714
  // Toggle tool
62618
62715
  var handleToggleTool = function handleToggleTool(toolName) {
62619
62716
  setEnabledTools(function (prev) {
@@ -62638,29 +62735,21 @@ function ChatCore(_ref) {
62638
62735
  className: "inline-block w-2 h-2 rounded-full bg-green-400",
62639
62736
  title: "CLI session active"
62640
62737
  })]
62641
- }), /*#__PURE__*/jsxs("div", {
62738
+ }), /*#__PURE__*/jsx("div", {
62642
62739
  className: "flex items-center gap-1",
62643
- children: [isCliBackend && sessionActive && /*#__PURE__*/jsx("button", {
62644
- onClick: handleEndSession,
62645
- className: "px-2 py-1 text-xs rounded bg-red-900/50 hover:bg-red-800/50 text-red-300 transition-colors",
62646
- children: "End Session"
62647
- }), /*#__PURE__*/jsx("button", {
62740
+ children: /*#__PURE__*/jsx("button", {
62648
62741
  onClick: handleNewChat,
62649
62742
  className: "px-2 py-1 text-xs rounded bg-gray-700 hover:bg-gray-600 text-gray-300 transition-colors",
62650
62743
  children: "New Chat"
62651
- })]
62744
+ })
62652
62745
  })]
62653
- }) : /*#__PURE__*/jsxs("div", {
62746
+ }) : /*#__PURE__*/jsx("div", {
62654
62747
  className: "flex items-center justify-end px-3 py-1 shrink-0",
62655
- children: [isCliBackend && sessionActive && /*#__PURE__*/jsx("button", {
62656
- onClick: handleEndSession,
62657
- className: "px-2 py-1 text-xs rounded bg-red-900/50 hover:bg-red-800/50 text-red-300 transition-colors mr-1",
62658
- children: "End Session"
62659
- }), /*#__PURE__*/jsx("button", {
62748
+ children: /*#__PURE__*/jsx("button", {
62660
62749
  onClick: handleNewChat,
62661
62750
  className: "px-2 py-1 text-xs rounded bg-gray-700 hover:bg-gray-600 text-gray-300 transition-colors",
62662
62751
  children: "New Chat"
62663
- })]
62752
+ })
62664
62753
  }), error && /*#__PURE__*/jsxs("div", {
62665
62754
  className: "mx-3 mt-2 p-2 bg-red-900/30 border border-red-700 rounded text-red-300 text-xs",
62666
62755
  children: [error, /*#__PURE__*/jsx("button", {