@morscherlab/mint-sdk 1.5.0-beta.7 → 1.5.0-beta.9

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.
Files changed (105) hide show
  1. package/dist/{AlertBox-CexONPhA.js → AlertBox-Cai0w7gF.js} +3 -3
  2. package/dist/{AlertBox-CexONPhA.js.map → AlertBox-Cai0w7gF.js.map} +1 -1
  3. package/dist/{AppSidebar-C4qQLHcH.js → AppSidebar-C-Vq5x4I.js} +361 -93
  4. package/dist/AppSidebar-C-Vq5x4I.js.map +1 -0
  5. package/dist/{ConfirmDialog-D9QXFpsy.js → ConfirmDialog-BjFsOpBe.js} +2 -2
  6. package/dist/{ConfirmDialog-D9QXFpsy.js.map → ConfirmDialog-BjFsOpBe.js.map} +1 -1
  7. package/dist/{ExperimentPopover-DyjoXwry.js → ExperimentPopover-DYy_s0kI.js} +21 -20
  8. package/dist/ExperimentPopover-DYy_s0kI.js.map +1 -0
  9. package/dist/{ExperimentSelectorModal-CUkKmgfr.js → ExperimentSelectorModal-Bfh5bdkv.js} +5 -5
  10. package/dist/{ExperimentSelectorModal-CUkKmgfr.js.map → ExperimentSelectorModal-Bfh5bdkv.js.map} +1 -1
  11. package/dist/{SegmentedControl-C-sckoJZ.js → SegmentedControl-B8KgyOjd.js} +2 -2
  12. package/dist/{SegmentedControl-C-sckoJZ.js.map → SegmentedControl-B8KgyOjd.js.map} +1 -1
  13. package/dist/{SettingsModal-B1ltysmg.js → SettingsModal-DwfrD1ER.js} +7 -7
  14. package/dist/{SettingsModal-B1ltysmg.js.map → SettingsModal-DwfrD1ER.js.map} +1 -1
  15. package/dist/__tests__/components/AppTopBarCompact.test.d.ts +1 -0
  16. package/dist/__tests__/components/AppTopBarCompactReset.test.d.ts +1 -0
  17. package/dist/__tests__/components/AutoGroupModal.experimentLoad.test.d.ts +1 -0
  18. package/dist/components/AppTopBar.compact.d.ts +5 -0
  19. package/dist/components/AppTopBar.vue.d.ts +17 -17
  20. package/dist/components/PluginWorkspaceView.vue.d.ts +4 -0
  21. package/dist/components/internal/AppTopBarPageSelectorInternal.vue.d.ts +2 -2
  22. package/dist/components/internal/LucideIconInternal.vue.d.ts +17 -0
  23. package/dist/composables/appLayoutSidebar.d.ts +9 -0
  24. package/dist/composables/usePluginWorkspace.d.ts +2 -0
  25. package/dist/composables/useVersionedSave.d.ts +5 -2
  26. package/dist/{controlSchemaModel-C_XqpkgE.js → controlSchemaModel-BtFNZj8t.js} +2 -2
  27. package/dist/{controlSchemaModel-C_XqpkgE.js.map → controlSchemaModel-BtFNZj8t.js.map} +1 -1
  28. package/dist/{data-CgIcnf9D.js → data-CJztFns8.js} +31 -15
  29. package/dist/{data-CgIcnf9D.js.map → data-CJztFns8.js.map} +1 -1
  30. package/dist/data.js +8 -8
  31. package/dist/{experimentStatus-DCn2QKG7.js → experimentStatus-Deokk7Br.js} +2 -2
  32. package/dist/{experimentStatus-DCn2QKG7.js.map → experimentStatus-Deokk7Br.js.map} +1 -1
  33. package/dist/index.js +14 -14
  34. package/dist/{install-DmyjbTJ5.js → install-Bk02tJ5M.js} +14 -15
  35. package/dist/{install-DmyjbTJ5.js.map → install-Bk02tJ5M.js.map} +1 -1
  36. package/dist/install.js +1 -1
  37. package/dist/{lab-BcX5JBSY.js → lab-BYhb_cJI.js} +22 -14
  38. package/dist/lab-BYhb_cJI.js.map +1 -0
  39. package/dist/lab.js +4 -4
  40. package/dist/{records-BAymyHAn.js → records-GtiVMlTQ.js} +198 -62
  41. package/dist/records-GtiVMlTQ.js.map +1 -0
  42. package/dist/{runtime-CjfAxufu.js → runtime-aZPUPxoB.js} +40 -19
  43. package/dist/runtime-aZPUPxoB.js.map +1 -0
  44. package/dist/runtime.js +6 -6
  45. package/dist/{shell-XDqDu_UD.js → shell-Bk9mD4Lc.js} +5 -5
  46. package/dist/{shell-XDqDu_UD.js.map → shell-Bk9mD4Lc.js.map} +1 -1
  47. package/dist/shell.js +5 -5
  48. package/dist/styles.css +138 -13
  49. package/dist/types/components.d.ts +22 -2
  50. package/dist/types/index.d.ts +1 -1
  51. package/dist/{useDropdownState-uFIz6Yv8.js → useDropdownState-CcBzUYZ6.js} +14 -5
  52. package/dist/useDropdownState-CcBzUYZ6.js.map +1 -0
  53. package/dist/{useExperimentSamples-DEDAKa2E.js → useExperimentSamples-CpNXvpUn.js} +3 -3
  54. package/dist/{useExperimentSamples-DEDAKa2E.js.map → useExperimentSamples-CpNXvpUn.js.map} +1 -1
  55. package/dist/{useListReorder-W1bzK_bo.js → useListReorder-Bp4EAI2w.js} +3 -3
  56. package/dist/{useListReorder-W1bzK_bo.js.map → useListReorder-Bp4EAI2w.js.map} +1 -1
  57. package/dist/{useRackEditor-Bmtuo0aj.js → useRackEditor-i2bdPUFf.js} +8 -8
  58. package/dist/{useRackEditor-Bmtuo0aj.js.map → useRackEditor-i2bdPUFf.js.map} +1 -1
  59. package/dist/{useRealtime-jOetF2mM.js → useRealtime-BLQEjbuq.js} +3 -3
  60. package/dist/{useRealtime-jOetF2mM.js.map → useRealtime-BLQEjbuq.js.map} +1 -1
  61. package/dist/useRequest-CXyPw3eh.js +76 -0
  62. package/dist/useRequest-CXyPw3eh.js.map +1 -0
  63. package/dist/utils/deprecation.d.ts +2 -0
  64. package/dist/utils/lucideIcon.d.ts +4 -0
  65. package/package.json +1 -1
  66. package/src/__tests__/components/AppTopBar.test.ts +102 -20
  67. package/src/__tests__/components/AppTopBarCompact.test.ts +65 -0
  68. package/src/__tests__/components/AppTopBarCompactReset.test.ts +24 -0
  69. package/src/__tests__/components/AutoGroupModal.experimentLoad.test.ts +58 -0
  70. package/src/__tests__/components/BaseModal.test.ts +33 -2
  71. package/src/__tests__/components/PluginWorkspaceView.test.ts +20 -1
  72. package/src/__tests__/composables/useJobCenter.test.ts +35 -0
  73. package/src/__tests__/composables/useVersionedSave.test.ts +71 -6
  74. package/src/__tests__/styles/menusShellRefresh.test.ts +10 -0
  75. package/src/components/AppLayout.story.vue +5 -5
  76. package/src/components/AppLayout.vue +13 -1
  77. package/src/components/AppTopBar.compact.ts +60 -0
  78. package/src/components/AppTopBar.story.vue +39 -14
  79. package/src/components/AppTopBar.vue +222 -89
  80. package/src/components/BaseModal.vue +16 -5
  81. package/src/components/ExperimentPopover.vue +1 -1
  82. package/src/components/GeneratedPluginView.vue +0 -1
  83. package/src/components/PluginWorkspaceView.vue +10 -1
  84. package/src/components/internal/AppTopBarPageSelectorInternal.vue +12 -0
  85. package/src/components/internal/AutoGroupModalInternal.vue +14 -3
  86. package/src/components/internal/LucideIconInternal.vue +23 -0
  87. package/src/composables/appLayoutSidebar.ts +11 -0
  88. package/src/composables/useJobCenter.ts +21 -1
  89. package/src/composables/usePluginWorkspace.ts +15 -4
  90. package/src/composables/useVersionedSave.ts +32 -7
  91. package/src/styles/components/app-layout.css +5 -0
  92. package/src/styles/components/app-top-bar.css +130 -9
  93. package/src/types/components.ts +23 -2
  94. package/src/types/index.ts +1 -0
  95. package/src/utils/deprecation.ts +8 -0
  96. package/src/utils/lucideIcon.ts +25 -0
  97. package/src/utils/lucideIconIndex.d.ts +2 -0
  98. package/dist/AppSidebar-C4qQLHcH.js.map +0 -1
  99. package/dist/ExperimentPopover-DyjoXwry.js.map +0 -1
  100. package/dist/lab-BcX5JBSY.js.map +0 -1
  101. package/dist/records-BAymyHAn.js.map +0 -1
  102. package/dist/runtime-CjfAxufu.js.map +0 -1
  103. package/dist/useDropdownState-uFIz6Yv8.js.map +0 -1
  104. package/dist/useRequest-D9-3BS-3.js +0 -215
  105. package/dist/useRequest-D9-3BS-3.js.map +0 -1
@@ -1,9 +1,9 @@
1
- import { a as BaseButton_default, i as useEventListener, t as useDropdownState } from "./useDropdownState-uFIz6Yv8.js";
1
+ import { a as BaseButton_default, i as useEventListener, t as useDropdownState } from "./useDropdownState-CcBzUYZ6.js";
2
2
  import { n as integrationHost, u as useSettingsStore } from "./experiment-DyO54FQB.js";
3
- import { E as useMenuKeyboard, I as FormField_default, _ as APP_EXPERIMENT_KEY, t as isRecord, z as BaseCheckbox_default } from "./records-BAymyHAn.js";
4
- import { F as applySpecDefaults, M as usePlatform, _ as getTypeDefault, a as StepWizard_default, c as normalizeControls, d as numericValue, g as getFieldRegistryEntry, l as normalizeOption, o as defaultValueForControl, p as orderedUnique, u as humanize } from "./useListReorder-W1bzK_bo.js";
5
- import { Fragment, Teleport, Transition, computed, createBlock, createCommentVNode, createElementBlock, createElementVNode, createSlots, createTextVNode, createVNode, defineAsyncComponent, defineComponent, guardReactiveProps, inject, mergeProps, nextTick, normalizeClass, normalizeProps, normalizeStyle, onBeforeUnmount, onMounted, onScopeDispose, openBlock, provide, reactive, readonly, ref, renderList, renderSlot, resolveComponent, resolveDynamicComponent, shallowRef, toDisplayString, toRaw, toValue, unref, useId, useSlots, useTemplateRef, vShow, watch, withCtx, withDirectives, withModifiers } from "vue";
6
- import { Check, CircleAlert, CircleCheck, CircleHelp, CircleX, ListChecks, LoaderCircle, Moon, Play, Sun, X } from "lucide-vue-next";
3
+ import { B as BaseCheckbox_default, D as useMenuKeyboard, L as FormField_default, T as ActionMenu_default, _ as APP_EXPERIMENT_KEY, t as isRecord } from "./records-GtiVMlTQ.js";
4
+ import { F as applySpecDefaults, M as usePlatform, _ as getTypeDefault, a as StepWizard_default, c as normalizeControls, d as numericValue, g as getFieldRegistryEntry, l as normalizeOption, o as defaultValueForControl, p as orderedUnique, u as humanize } from "./useListReorder-Bp4EAI2w.js";
5
+ import { Fragment, Teleport, Transition, computed, createBlock, createCommentVNode, createElementBlock, createElementVNode, createSlots, createTextVNode, createVNode, defineAsyncComponent, defineComponent, guardReactiveProps, inject, mergeProps, nextTick, normalizeClass, normalizeProps, normalizeStyle, onBeforeUnmount, onMounted, onScopeDispose, openBlock, provide, reactive, readonly, ref, renderList, renderSlot, resolveComponent, resolveDynamicComponent, shallowRef, toDisplayString, toRaw, toValue, unref, useId, useSlots, useTemplateRef, vShow, watch, watchEffect, withCtx, withDirectives, withModifiers } from "vue";
6
+ import { Check, CircleAlert, CircleCheck, CircleHelp, CircleX, Ellipsis, ListChecks, LoaderCircle, Menu, Moon, Play, Sun, X } from "lucide-vue-next";
7
7
  import { autoUpdate, computePosition, flip, offset, shift } from "@floating-ui/dom";
8
8
  //#region src/composables/useTheme.ts
9
9
  /** Reads and toggles the active theme (light/dark/system) with reactivity to OS preference changes. */
@@ -81,11 +81,11 @@ var _hoisted_11$6 = {
81
81
  };
82
82
  var _hoisted_12$5 = ["d"];
83
83
  var _hoisted_13$5 = ["d"];
84
- var _hoisted_14$3 = {
84
+ var _hoisted_14$4 = {
85
85
  key: 1,
86
86
  class: "mint-collapsible-card__action-text-icon"
87
87
  };
88
- var _hoisted_15$3 = [
88
+ var _hoisted_15$4 = [
89
89
  "disabled",
90
90
  "aria-label",
91
91
  "aria-expanded"
@@ -216,7 +216,7 @@ var CollapsibleCard_default = /* @__PURE__ */ defineComponent({
216
216
  }), 128)) : (openBlock(), createElementBlock("path", {
217
217
  key: 1,
218
218
  d: action.icon
219
- }, null, 8, _hoisted_13$5))])) : action.icon ? (openBlock(), createElementBlock("span", _hoisted_14$3, toDisplayString(action.icon), 1)) : createCommentVNode("", true)], 14, _hoisted_10$6);
219
+ }, null, 8, _hoisted_13$5))])) : action.icon ? (openBlock(), createElementBlock("span", _hoisted_14$4, toDisplayString(action.icon), 1)) : createCommentVNode("", true)], 14, _hoisted_10$6);
220
220
  }), 128)),
221
221
  __props.showToggle ? (openBlock(), createElementBlock("div", {
222
222
  key: 1,
@@ -245,7 +245,7 @@ var CollapsibleCard_default = /* @__PURE__ */ defineComponent({
245
245
  "stroke-linejoin": "round",
246
246
  viewBox: "0 0 24 24",
247
247
  "aria-hidden": "true"
248
- }, [..._cache[2] || (_cache[2] = [createElementVNode("path", { d: "m6 9 6 6 6-6" }, null, -1)])], 2))], 8, _hoisted_15$3)
248
+ }, [..._cache[2] || (_cache[2] = [createElementVNode("path", { d: "m6 9 6 6 6-6" }, null, -1)])], 2))], 8, _hoisted_15$4)
249
249
  ])]), createVNode(Transition, { name: "collapse" }, {
250
250
  default: withCtx(() => [withDirectives(createElementVNode("div", _hoisted_16$3, [createElementVNode("div", _hoisted_17$2, [renderSlot(_ctx.$slots, "default")])], 512), [[vShow, isOpen.value]])]),
251
251
  _: 3
@@ -763,7 +763,6 @@ function usePluginWorkspace(options) {
763
763
  const { props, slots, emit } = options;
764
764
  const sidebarSpec = computed(() => props.spec?.sidebar ?? {});
765
765
  const topBarSpec = computed(() => props.spec?.topBar === false ? false : applySpecDefaults({
766
- themeToggle: true,
767
766
  settings: {},
768
767
  standaloneLabel: false
769
768
  }, props.spec?.topBar));
@@ -787,6 +786,12 @@ function usePluginWorkspace(options) {
787
786
  });
788
787
  const topBarSlotNames = computed(() => getPluginWorkspaceTopBarSlotNames(slots));
789
788
  const sidebarSlotNames = computed(() => getPluginWorkspaceSidebarSlotNames(slots));
789
+ const internalCollapsed = ref(false);
790
+ const sidebarCollapsed = computed(() => props.sidebarCollapsed ?? internalCollapsed.value);
791
+ function handleSidebarCollapsedUpdate(value) {
792
+ internalCollapsed.value = value;
793
+ emit("update:sidebarCollapsed", value);
794
+ }
790
795
  const hasSidebarSurface = computed(() => hasPluginWorkspaceSidebarSurface({
791
796
  sidebar: sidebarSpec.value,
792
797
  hasSidebarSlot: Boolean(slots.sidebar),
@@ -806,7 +811,7 @@ function usePluginWorkspace(options) {
806
811
  const sidebar = sidebarSpec.value === false ? {} : sidebarSpec.value;
807
812
  return {
808
813
  sidebarPosition: sidebar.position ?? "left",
809
- sidebarWidth: sidebar.width,
814
+ sidebarWidth: sidebarCollapsed.value ? sidebar.collapsedWidth ?? "3rem" : sidebar.width,
810
815
  floating: props.spec?.floating ?? true,
811
816
  responsiveSidebar: sidebar.responsive ?? true,
812
817
  sidebarToggleLabel: sidebar.toggleLabel ?? "Open workspace sidebar",
@@ -834,7 +839,7 @@ function usePluginWorkspace(options) {
834
839
  },
835
840
  activeView: navigationState.resolvedActiveView.value,
836
841
  values: controlsState.internalControlValues,
837
- collapsed: props.sidebarCollapsed,
842
+ collapsed: sidebarCollapsed.value,
838
843
  formLoading: props.formLoading ?? false,
839
844
  formDisabled: props.formDisabled ?? false,
840
845
  formReadonly: props.formReadonly ?? false,
@@ -844,10 +849,23 @@ function usePluginWorkspace(options) {
844
849
  controls,
845
850
  hasSidebarSurface,
846
851
  handleControlValuesUpdate: controlsState.handleControlValuesUpdate,
847
- handlePillSelect: navigationState.handlePillSelect
852
+ handlePillSelect: navigationState.handlePillSelect,
853
+ handleSidebarCollapsedUpdate
848
854
  };
849
855
  }
850
856
  //#endregion
857
+ //#region src/utils/deprecation.ts
858
+ var warned = /* @__PURE__ */ new Set();
859
+ /** Warn once per page load that a deprecated SDK option or slot is in use. */
860
+ function warnDeprecatedOnce(key, message) {
861
+ if (warned.has(key)) return;
862
+ warned.add(key);
863
+ console.warn(`[mint-sdk] ${message}`);
864
+ }
865
+ //#endregion
866
+ //#region src/composables/appLayoutSidebar.ts
867
+ var APP_LAYOUT_SIDEBAR_KEY = Symbol("mint-app-layout-sidebar");
868
+ //#endregion
851
869
  //#region src/components/AppLayout.vue?vue&type=script&setup=true&lang.ts
852
870
  var _hoisted_1$11 = {
853
871
  key: 0,
@@ -930,6 +948,7 @@ var AppLayout_default = /* @__PURE__ */ defineComponent({
930
948
  */
931
949
  const props = __props;
932
950
  const emit = __emit;
951
+ const slots = useSlots();
933
952
  const internalSidebarOpen = ref(props.defaultSidebarOpen);
934
953
  const sidebarOpenModel = computed({
935
954
  get: () => props.sidebarOpen ?? internalSidebarOpen.value,
@@ -951,6 +970,12 @@ var AppLayout_default = /* @__PURE__ */ defineComponent({
951
970
  function toggleSidebar() {
952
971
  sidebarOpenModel.value = !sidebarOpenModel.value;
953
972
  }
973
+ if (props.responsiveSidebar && slots.sidebar) provide(APP_LAYOUT_SIDEBAR_KEY, {
974
+ open: computed(() => sidebarOpenModel.value),
975
+ toggle: toggleSidebar,
976
+ openLabel: computed(() => props.sidebarToggleLabel),
977
+ closeLabel: computed(() => props.sidebarCloseLabel)
978
+ });
954
979
  function closeSidebar() {
955
980
  sidebarOpenModel.value = false;
956
981
  }
@@ -980,6 +1005,51 @@ var AppLayout_default = /* @__PURE__ */ defineComponent({
980
1005
  }
981
1006
  });
982
1007
  //#endregion
1008
+ //#region src/utils/lucideIcon.ts
1009
+ /** A Lucide icon name in kebab case, such as `activity` or `flask-conical`. */
1010
+ var LUCIDE_NAME = /^[a-z][a-z0-9]*(?:-[a-z0-9]+)*$/;
1011
+ function isLucideIconName(value) {
1012
+ return !!value && LUCIDE_NAME.test(value);
1013
+ }
1014
+ function pascalCase(name) {
1015
+ return name.replace(/(^|-)([a-z0-9])/g, (_, __, char) => char.toUpperCase());
1016
+ }
1017
+ var iconSet;
1018
+ /** The Lucide component for `name`, or undefined when Lucide has no such icon. */
1019
+ async function loadLucideIcon(name) {
1020
+ iconSet ??= import("lucide-vue-next/dist/esm/icons/index.js");
1021
+ return (await iconSet)[pascalCase(name)];
1022
+ }
1023
+ //#endregion
1024
+ //#region src/components/internal/LucideIconInternal.vue
1025
+ var LucideIconInternal_default = /* @__PURE__ */ defineComponent({
1026
+ __name: "LucideIconInternal",
1027
+ props: {
1028
+ name: {},
1029
+ size: {}
1030
+ },
1031
+ setup(__props) {
1032
+ /** Internal: renders a Lucide icon by name; shows `fallback` until it loads or when the name is unknown. */
1033
+ const props = __props;
1034
+ const icon = shallowRef();
1035
+ watchEffect(async (onCleanup) => {
1036
+ let stale = false;
1037
+ onCleanup(() => {
1038
+ stale = true;
1039
+ });
1040
+ const loaded = await loadLucideIcon(props.name);
1041
+ if (!stale) icon.value = loaded;
1042
+ });
1043
+ return (_ctx, _cache) => {
1044
+ return icon.value ? (openBlock(), createBlock(resolveDynamicComponent(icon.value), {
1045
+ key: 0,
1046
+ size: __props.size ?? 14,
1047
+ "aria-hidden": "true"
1048
+ }, null, 8, ["size"])) : renderSlot(_ctx.$slots, "fallback", {}, void 0, void 0, 1);
1049
+ };
1050
+ }
1051
+ });
1052
+ //#endregion
983
1053
  //#region src/utils/items.ts
984
1054
  function normalizeItemInput(item) {
985
1055
  if (typeof item === "object") return item;
@@ -1374,31 +1444,33 @@ var _hoisted_1$8 = {
1374
1444
  };
1375
1445
  var _hoisted_2$6 = { class: "mint-page-selector__plugin" };
1376
1446
  var _hoisted_3$6 = ["aria-expanded"];
1377
- var _hoisted_4$6 = {
1378
- key: 1,
1447
+ var _hoisted_4$6 = { class: "mint-page-selector__icon-fallback" };
1448
+ var _hoisted_5$6 = {
1449
+ key: 2,
1379
1450
  class: "mint-page-selector__icon-fallback"
1380
1451
  };
1381
- var _hoisted_5$6 = { class: "mint-page-selector__label" };
1382
- var _hoisted_6$5 = {
1452
+ var _hoisted_6$5 = { class: "mint-page-selector__label" };
1453
+ var _hoisted_7$5 = {
1383
1454
  class: "mint-page-selector__chevron-wrap",
1384
1455
  "aria-hidden": "true"
1385
1456
  };
1386
- var _hoisted_7$5 = ["aria-label"];
1387
- var _hoisted_8$5 = {
1457
+ var _hoisted_8$5 = ["aria-label"];
1458
+ var _hoisted_9$5 = {
1388
1459
  class: "mint-page-selector__menu-title",
1389
1460
  "aria-hidden": "true"
1390
1461
  };
1391
- var _hoisted_9$5 = {
1392
- key: 1,
1462
+ var _hoisted_10$5 = { class: "mint-page-selector__icon-fallback" };
1463
+ var _hoisted_11$5 = {
1464
+ key: 2,
1393
1465
  class: "mint-page-selector__icon-fallback"
1394
1466
  };
1395
- var _hoisted_10$5 = { class: "mint-page-selector__item-text" };
1396
- var _hoisted_11$5 = { class: "mint-page-selector__item-label" };
1397
- var _hoisted_12$4 = {
1467
+ var _hoisted_12$4 = { class: "mint-page-selector__item-text" };
1468
+ var _hoisted_13$4 = { class: "mint-page-selector__item-label" };
1469
+ var _hoisted_14$3 = {
1398
1470
  key: 0,
1399
1471
  class: "mint-page-selector__item-hint"
1400
1472
  };
1401
- var _hoisted_13$4 = {
1473
+ var _hoisted_15$3 = {
1402
1474
  key: 0,
1403
1475
  class: "mint-page-selector__item-key",
1404
1476
  "aria-hidden": "true"
@@ -1503,9 +1575,15 @@ var AppTopBarPageSelectorInternal_default = /* @__PURE__ */ defineComponent({
1503
1575
  icon: current.value.icon,
1504
1576
  size: "sm",
1505
1577
  variant: "solid"
1506
- }, null, 8, ["icon"])) : (openBlock(), createElementBlock("span", _hoisted_4$6, toDisplayString(current.value.label.charAt(0)), 1))])], 2)) : createCommentVNode("", true),
1507
- createElementVNode("span", _hoisted_5$6, toDisplayString(current.value?.label ?? __props.placeholder), 1),
1508
- createElementVNode("span", _hoisted_6$5, [(openBlock(), createElementBlock("svg", {
1578
+ }, null, 8, ["icon"])) : unref(isLucideIconName)(current.value.icon) ? (openBlock(), createBlock(LucideIconInternal_default, {
1579
+ key: 1,
1580
+ name: current.value.icon
1581
+ }, {
1582
+ fallback: withCtx(() => [createElementVNode("span", _hoisted_4$6, toDisplayString(current.value.label.charAt(0)), 1)]),
1583
+ _: 1
1584
+ }, 8, ["name"])) : (openBlock(), createElementBlock("span", _hoisted_5$6, toDisplayString(current.value.label.charAt(0)), 1))])], 2)) : createCommentVNode("", true),
1585
+ createElementVNode("span", _hoisted_6$5, toDisplayString(current.value?.label ?? __props.placeholder), 1),
1586
+ createElementVNode("span", _hoisted_7$5, [(openBlock(), createElementBlock("svg", {
1509
1587
  class: normalizeClass(["mint-page-selector__chevron", { "mint-page-selector__chevron--open": unref(isOpen) }]),
1510
1588
  viewBox: "0 0 24 24",
1511
1589
  fill: "none",
@@ -1521,7 +1599,7 @@ var AppTopBarPageSelectorInternal_default = /* @__PURE__ */ defineComponent({
1521
1599
  role: "menu",
1522
1600
  "aria-label": menuTitle.value,
1523
1601
  onKeydown: handleMenuKeydown
1524
- }, [createElementVNode("div", _hoisted_8$5, toDisplayString(menuTitle.value), 1), (openBlock(true), createElementBlock(Fragment, null, renderList(normalizedPages.value, (page, index) => {
1602
+ }, [createElementVNode("div", _hoisted_9$5, toDisplayString(menuTitle.value), 1), (openBlock(true), createElementBlock(Fragment, null, renderList(normalizedPages.value, (page, index) => {
1525
1603
  return openBlock(), createBlock(ActionItemInternal_default, {
1526
1604
  key: page.id,
1527
1605
  href: page.href,
@@ -1544,9 +1622,15 @@ var AppTopBarPageSelectorInternal_default = /* @__PURE__ */ defineComponent({
1544
1622
  icon: page.icon,
1545
1623
  size: "sm",
1546
1624
  variant: "solid"
1547
- }, null, 8, ["icon"])) : (openBlock(), createElementBlock("span", _hoisted_9$5, toDisplayString(page.label.charAt(0)), 1))])], 2),
1548
- createElementVNode("span", _hoisted_10$5, [createElementVNode("span", _hoisted_11$5, toDisplayString(page.label), 1), page.hint ? (openBlock(), createElementBlock("span", _hoisted_12$4, toDisplayString(page.hint), 1)) : createCommentVNode("", true)]),
1549
- index < 9 ? (openBlock(), createElementBlock("span", _hoisted_13$4, toDisplayString(index + 1), 1)) : createCommentVNode("", true)
1625
+ }, null, 8, ["icon"])) : unref(isLucideIconName)(page.icon) ? (openBlock(), createBlock(LucideIconInternal_default, {
1626
+ key: 1,
1627
+ name: page.icon
1628
+ }, {
1629
+ fallback: withCtx(() => [createElementVNode("span", _hoisted_10$5, toDisplayString(page.label.charAt(0)), 1)]),
1630
+ _: 2
1631
+ }, 1032, ["name"])) : (openBlock(), createElementBlock("span", _hoisted_11$5, toDisplayString(page.label.charAt(0)), 1))])], 2),
1632
+ createElementVNode("span", _hoisted_12$4, [createElementVNode("span", _hoisted_13$4, toDisplayString(page.label), 1), page.hint ? (openBlock(), createElementBlock("span", _hoisted_14$3, toDisplayString(page.hint), 1)) : createCommentVNode("", true)]),
1633
+ index < 9 ? (openBlock(), createElementBlock("span", _hoisted_15$3, toDisplayString(index + 1), 1)) : createCommentVNode("", true)
1550
1634
  ]),
1551
1635
  _: 2
1552
1636
  }, 1032, [
@@ -1558,7 +1642,7 @@ var AppTopBarPageSelectorInternal_default = /* @__PURE__ */ defineComponent({
1558
1642
  "aria-keyshortcuts",
1559
1643
  "onClick"
1560
1644
  ]);
1561
- }), 128))], 40, _hoisted_7$5)) : createCommentVNode("", true)], 4)], 512);
1645
+ }), 128))], 40, _hoisted_8$5)) : createCommentVNode("", true)], 4)], 512);
1562
1646
  };
1563
1647
  }
1564
1648
  });
@@ -2647,9 +2731,53 @@ function trackTopBarForToasts(el) {
2647
2731
  };
2648
2732
  }
2649
2733
  //#endregion
2734
+ //#region src/components/AppTopBar.compact.ts
2735
+ var CHIP_MIN_PX = 192;
2736
+ var LABELS = ".mint-experiment-popover__save-label, .mint-topbar__job-label";
2737
+ /** Identity text that truncates when the left side is squeezed. */
2738
+ var IDENTITY_TEXT = ".mint-page-selector__plugin, .mint-page-selector__label, .mint-topbar__plugin-name, .mint-topbar-title, .mint-topbar__title-only";
2739
+ function overflows(el) {
2740
+ return !!el && el.scrollWidth > el.clientWidth + 1;
2741
+ }
2742
+ function trackTopBarCompact(header, compact) {
2743
+ if (typeof ResizeObserver === "undefined") return {
2744
+ reset: () => {},
2745
+ stop: () => {}
2746
+ };
2747
+ let expandAt = 0;
2748
+ function check() {
2749
+ const width = header.clientWidth;
2750
+ if (compact.value) {
2751
+ if (width >= expandAt) compact.value = false;
2752
+ return;
2753
+ }
2754
+ const chip = header.querySelector(".mint-experiment-popover__trigger");
2755
+ if (!(chip && chip.getBoundingClientRect().width < CHIP_MIN_PX && overflows(chip.querySelector(".mint-experiment-popover__trigger-text")) || [...header.querySelectorAll(IDENTITY_TEXT)].some(overflows) || overflows(header.querySelector(".mint-topbar__center")) || overflows(header.querySelector(".mint-topbar__context")))) return;
2756
+ const labelsWidth = [...header.querySelectorAll(LABELS)].reduce((sum, el) => sum + el.getBoundingClientRect().width, 0);
2757
+ if (labelsWidth === 0) return;
2758
+ expandAt = width + labelsWidth;
2759
+ compact.value = true;
2760
+ }
2761
+ const observer = new ResizeObserver(check);
2762
+ function observe() {
2763
+ observer.disconnect();
2764
+ observer.observe(header);
2765
+ for (const el of header.querySelectorAll(".mint-topbar__center, .mint-topbar__context")) observer.observe(el);
2766
+ }
2767
+ observe();
2768
+ return {
2769
+ reset: () => {
2770
+ compact.value = false;
2771
+ expandAt = 0;
2772
+ requestAnimationFrame(observe);
2773
+ },
2774
+ stop: () => observer.disconnect()
2775
+ };
2776
+ }
2777
+ //#endregion
2650
2778
  //#region src/components/AppTopBar.vue?vue&type=script&setup=true&lang.ts
2651
- var _hoisted_1$4 = { class: "mint-topbar__container" };
2652
- var _hoisted_2$2 = { class: "mint-topbar__start" };
2779
+ var _hoisted_1$4 = { class: "mint-topbar__start" };
2780
+ var _hoisted_2$2 = ["aria-label", "aria-expanded"];
2653
2781
  var _hoisted_3$2 = { class: "mint-topbar__brand" };
2654
2782
  var _hoisted_4$2 = ["href"];
2655
2783
  var _hoisted_5$2 = {
@@ -2677,7 +2805,7 @@ var _hoisted_10$1 = {
2677
2805
  class: "mint-topbar__logo"
2678
2806
  };
2679
2807
  var _hoisted_11$1 = {
2680
- key: 0,
2808
+ key: 1,
2681
2809
  class: "mint-topbar__plugin-identity"
2682
2810
  };
2683
2811
  var _hoisted_12$1 = { class: "mint-topbar__plugin-name" };
@@ -2686,13 +2814,13 @@ var _hoisted_13$1 = {
2686
2814
  class: "mint-topbar__plugin-subtitle"
2687
2815
  };
2688
2816
  var _hoisted_14$1 = {
2689
- key: 3,
2817
+ key: 4,
2690
2818
  class: "mint-topbar-title-group"
2691
2819
  };
2692
2820
  var _hoisted_15$1 = { class: "mint-topbar-title" };
2693
2821
  var _hoisted_16$1 = { class: "mint-topbar-subtitle" };
2694
2822
  var _hoisted_17$1 = {
2695
- key: 4,
2823
+ key: 5,
2696
2824
  class: "mint-topbar__title-only"
2697
2825
  };
2698
2826
  var _hoisted_18$1 = {
@@ -2703,33 +2831,56 @@ var _hoisted_18$1 = {
2703
2831
  var _hoisted_19$1 = { class: "mint-topbar__right" };
2704
2832
  var _hoisted_20$1 = {
2705
2833
  key: 0,
2706
- class: "mint-topbar__standalone-badge"
2834
+ class: "mint-topbar__context"
2707
2835
  };
2708
2836
  var _hoisted_21$1 = {
2837
+ key: 0,
2838
+ class: "mint-topbar__standalone-badge"
2839
+ };
2840
+ var _hoisted_22$1 = {
2709
2841
  class: "mint-topbar__job-status",
2710
2842
  "aria-live": "polite"
2711
2843
  };
2712
- var _hoisted_22$1 = [
2844
+ var _hoisted_23$1 = [
2713
2845
  "title",
2714
2846
  "aria-label",
2715
2847
  "aria-expanded",
2716
2848
  "aria-controls"
2717
2849
  ];
2718
- var _hoisted_23$1 = {
2850
+ var _hoisted_24$1 = {
2719
2851
  key: 0,
2720
2852
  class: "mint-topbar__job-bar",
2721
2853
  "aria-hidden": "true"
2722
2854
  };
2723
- var _hoisted_24$1 = [
2855
+ var _hoisted_25$1 = [
2724
2856
  "aria-label",
2725
2857
  "aria-expanded",
2726
2858
  "aria-controls"
2727
2859
  ];
2728
- var _hoisted_25$1 = {
2860
+ var _hoisted_26$1 = {
2729
2861
  key: 0,
2730
2862
  class: "mint-topbar__job-count",
2731
2863
  "aria-hidden": "true"
2732
2864
  };
2865
+ var _hoisted_27$1 = [
2866
+ "aria-label",
2867
+ "title",
2868
+ "disabled",
2869
+ "aria-busy",
2870
+ "data-action",
2871
+ "onClick"
2872
+ ];
2873
+ var _hoisted_28$1 = [
2874
+ "aria-expanded",
2875
+ "onClick",
2876
+ "onKeydown"
2877
+ ];
2878
+ var _hoisted_29$1 = {
2879
+ key: 4,
2880
+ class: "mint-topbar__legacy-actions"
2881
+ };
2882
+ var _hoisted_30$1 = { class: "mint-topbar__tail" };
2883
+ var MAX_VISIBLE_ACTIONS = 2;
2733
2884
  //#endregion
2734
2885
  //#region src/components/AppTopBar.vue
2735
2886
  var AppTopBar_default = /* @__PURE__ */ defineComponent({
@@ -2762,29 +2913,50 @@ var AppTopBar_default = /* @__PURE__ */ defineComponent({
2762
2913
  * Full application top bar with brand logo, static plugin identity, page selector, centered pill nav, experiment popover, and an account slot.
2763
2914
  *
2764
2915
  * The `#icon` slot applies in standalone mode only; integrated branding comes from `Metadata.icon`.
2916
+ *
2917
+ * The order is fixed: identity or page selector, pills, the context group (standalone badge, run slot,
2918
+ * onboarding, `spec.actions`), then the tail: theme toggle, settings, `#account`. Below 1024px of bar
2919
+ * width the pills and the context group move to a second row. Inside a responsive AppLayout the bar
2920
+ * holds the sidebar drawer button.
2765
2921
  */
2766
2922
  const props = __props;
2767
2923
  const config = computed(() => applySpecDefaults({
2768
2924
  variant: "card",
2769
2925
  homePath: "/",
2770
2926
  logo: true,
2771
- themeToggle: false,
2772
- settings: false,
2773
2927
  standaloneLabel: "Standalone"
2774
2928
  }, props.spec));
2775
- const settingsConfig = computed(() => toValue(config.value.settings) || void 0);
2776
- const showSettings = computed(() => settingsConfig.value !== void 0);
2777
- const SettingsModal = defineAsyncComponent(() => import("./SettingsModal-B1ltysmg.js").then((n) => n.n));
2778
- const ExperimentPopover = defineAsyncComponent(() => import("./ExperimentPopover-DyjoXwry.js").then((n) => n.n));
2779
- const ExperimentSelectorModal = defineAsyncComponent(() => import("./ExperimentSelectorModal-CUkKmgfr.js").then((n) => n.n));
2929
+ const settingsConfig = computed(() => toValue(config.value.settings) || {});
2930
+ /** Plugin buttons: two show, the rest fold into the More menu. */
2931
+ const visibleActions = computed(() => (config.value.actions ?? []).slice(0, MAX_VISIBLE_ACTIONS));
2932
+ const overflowActions = computed(() => (config.value.actions ?? []).slice(MAX_VISIBLE_ACTIONS));
2933
+ const overflowMenuItems = computed(() => overflowActions.value.map(({ id, label, disabled, loading }) => ({
2934
+ id,
2935
+ label,
2936
+ disabled: disabled || loading
2937
+ })));
2938
+ function selectOverflowAction(item) {
2939
+ overflowActions.value.find((action) => action.id === item.id)?.onSelect();
2940
+ }
2941
+ const drawer = inject(APP_LAYOUT_SIDEBAR_KEY, null);
2942
+ const SettingsModal = defineAsyncComponent(() => import("./SettingsModal-DwfrD1ER.js").then((n) => n.n));
2943
+ const ExperimentPopover = defineAsyncComponent(() => import("./ExperimentPopover-DYy_s0kI.js").then((n) => n.n));
2944
+ const ExperimentSelectorModal = defineAsyncComponent(() => import("./ExperimentSelectorModal-Bfh5bdkv.js").then((n) => n.n));
2780
2945
  const emit = __emit;
2781
2946
  const settingsOpen = ref(false);
2782
2947
  const headerEl = ref(null);
2783
2948
  let untrackToastOffset;
2949
+ const compact = ref(false);
2950
+ let compactTracker;
2784
2951
  onMounted(() => {
2785
- if (headerEl.value) untrackToastOffset = trackTopBarForToasts(headerEl.value);
2952
+ if (!headerEl.value) return;
2953
+ untrackToastOffset = trackTopBarForToasts(headerEl.value);
2954
+ compactTracker = trackTopBarCompact(headerEl.value, compact);
2955
+ });
2956
+ onBeforeUnmount(() => {
2957
+ untrackToastOffset?.();
2958
+ compactTracker?.stop();
2786
2959
  });
2787
- onBeforeUnmount(() => untrackToastOffset?.());
2788
2960
  const { integrated: isIntegrated, plugin } = usePlatform();
2789
2961
  const isStandalone = computed(() => !isIntegrated.value);
2790
2962
  const appExperiment = inject(APP_EXPERIMENT_KEY, null);
@@ -2822,6 +2994,14 @@ var AppTopBar_default = /* @__PURE__ */ defineComponent({
2822
2994
  cancelled: CircleX
2823
2995
  };
2824
2996
  const slots = useSlots();
2997
+ if (props.spec.themeToggle !== void 0) warnDeprecatedOnce("topbar.themeToggle", "AppTopBar spec.themeToggle is ignored: the theme toggle always shows. Remove it; it is removed in 2.0.");
2998
+ for (const name of [
2999
+ "nav",
3000
+ "center",
3001
+ "actions",
3002
+ "page-selector-icon",
3003
+ "page-selector-item-icon"
3004
+ ]) if (slots[name]) warnDeprecatedOnce(`topbar.slot.${name}`, name.startsWith("page-selector") ? `AppTopBar #${name} is deprecated: give the page an icon (a Lucide name). It is removed in 2.0.` : `AppTopBar #${name} is deprecated${name === "actions" ? ": use spec.actions" : ""}. It is removed in 2.0.`);
2825
3005
  const pluginIcon = computed(() => plugin.value?.icon || (slots.logo ? void 0 : pluginIdentity.icon));
2826
3006
  const seeded = computed(() => isStandalone.value && !props.title && !props.subtitle);
2827
3007
  const titleText = computed(() => props.title || (seeded.value ? pluginIdentity.name : void 0));
@@ -2840,6 +3020,17 @@ var AppTopBar_default = /* @__PURE__ */ defineComponent({
2840
3020
  const pageSelectorPluginName = computed(() => isIntegrated.value ? plugin.value?.display_name || plugin.value?.name : props.title || pluginIdentity.name);
2841
3021
  const identitySubtitle = computed(() => plugin.value?.subtitle || plugin.value?.description);
2842
3022
  const hasPillNav = computed(() => !!config.value.pills?.length);
3023
+ const showStandaloneBadge = computed(() => config.value.standaloneLabel !== false && isStandalone.value);
3024
+ const showRunSlot = computed(() => showExperiment.value || props.job !== void 0 || runSlotJoined.value);
3025
+ /** The context group: standalone badge, run slot, onboarding and plugin buttons. Below 1024px it is row 2. */
3026
+ watch([
3027
+ () => config.value.actions?.map((action) => action.label).join(),
3028
+ () => props.job === void 0,
3029
+ () => props.job === null,
3030
+ showExperiment,
3031
+ () => config.value.pills?.length
3032
+ ], () => compactTracker?.reset());
3033
+ const hasContext = computed(() => showStandaloneBadge.value || showRunSlot.value || !!config.value.actions?.length || !!slots.actions || !!onboarding?.enabled.value);
2843
3034
  const hasTitleGroup = computed(() => !hasPageSelector.value && !identityName.value && !!titleText.value && !!subtitleText.value);
2844
3035
  const hasTitleOnly = computed(() => !hasPageSelector.value && !identityName.value && !hasTitleGroup.value && !!titleText.value);
2845
3036
  const normalizedPageSelector = computed(() => props.pageSelector?.map(normalizeItemInput) ?? []);
@@ -2855,9 +3046,24 @@ var AppTopBar_default = /* @__PURE__ */ defineComponent({
2855
3046
  createElementVNode("header", {
2856
3047
  ref_key: "headerEl",
2857
3048
  ref: headerEl,
2858
- class: normalizeClass(["mint-topbar", `mint-topbar--${config.value.variant}`])
2859
- }, [createElementVNode("div", _hoisted_1$4, [
2860
- createElementVNode("div", _hoisted_2$2, [
3049
+ class: normalizeClass([
3050
+ "mint-topbar",
3051
+ `mint-topbar--${config.value.variant}`,
3052
+ { "mint-topbar--compact": compact.value }
3053
+ ])
3054
+ }, [createElementVNode("div", { class: normalizeClass(["mint-topbar__container", { "mint-topbar__container--stackable": hasPillNav.value || _ctx.$slots.center || hasContext.value }]) }, [
3055
+ createElementVNode("div", _hoisted_1$4, [
3056
+ unref(drawer) ? (openBlock(), createElementBlock("button", {
3057
+ key: 0,
3058
+ type: "button",
3059
+ class: "mint-topbar__icon-btn mint-topbar__sidebar-toggle",
3060
+ "aria-label": unref(drawer).open.value ? unref(drawer).closeLabel.value : unref(drawer).openLabel.value,
3061
+ "aria-expanded": unref(drawer).open.value,
3062
+ onClick: _cache[0] || (_cache[0] = ($event) => unref(drawer).toggle())
3063
+ }, [(openBlock(), createBlock(resolveDynamicComponent(unref(drawer).open.value ? unref(X) : unref(Menu)), {
3064
+ class: "mint-topbar__icon-btn-icon",
3065
+ "aria-hidden": "true"
3066
+ }))], 8, _hoisted_2$2)) : createCommentVNode("", true),
2861
3067
  createElementVNode("div", _hoisted_3$2, [config.value.homePath && (config.value.homePath.startsWith("http") || config.value.homePath.startsWith("/")) ? (openBlock(), createElementBlock("a", {
2862
3068
  key: 0,
2863
3069
  href: config.value.homePath,
@@ -2874,7 +3080,7 @@ var AppTopBar_default = /* @__PURE__ */ defineComponent({
2874
3080
  icon: pluginIcon.value,
2875
3081
  size: "topbar",
2876
3082
  variant: "solid"
2877
- }, null, 8, ["icon"])) : renderSlot(_ctx.$slots, "logo", {}, () => [config.value.logo ? (openBlock(), createElementBlock("div", _hoisted_6$1, [..._cache[11] || (_cache[11] = [createElementVNode("div", { class: "mint-topbar__logo-icon" }, [createElementVNode("span", { class: "mint-topbar__logo-text" }, "M")], -1)])])) : createCommentVNode("", true)], void 0, 1)], void 0, 1)])) : createCommentVNode("", true)], 8, _hoisted_4$2)) : config.value.homePath ? (openBlock(), createBlock(_component_router_link, {
3083
+ }, null, 8, ["icon"])) : renderSlot(_ctx.$slots, "logo", {}, () => [config.value.logo ? (openBlock(), createElementBlock("div", _hoisted_6$1, [..._cache[12] || (_cache[12] = [createElementVNode("div", { class: "mint-topbar__logo-icon" }, [createElementVNode("span", { class: "mint-topbar__logo-text" }, "M")], -1)])])) : createCommentVNode("", true)], void 0, 1)], void 0, 1)])) : createCommentVNode("", true)], 8, _hoisted_4$2)) : config.value.homePath ? (openBlock(), createBlock(_component_router_link, {
2878
3084
  key: 1,
2879
3085
  to: config.value.homePath,
2880
3086
  class: "mint-topbar-home-link"
@@ -2891,7 +3097,7 @@ var AppTopBar_default = /* @__PURE__ */ defineComponent({
2891
3097
  icon: pluginIcon.value,
2892
3098
  size: "topbar",
2893
3099
  variant: "solid"
2894
- }, null, 8, ["icon"])) : renderSlot(_ctx.$slots, "logo", {}, () => [config.value.logo ? (openBlock(), createElementBlock("div", _hoisted_8$1, [..._cache[12] || (_cache[12] = [createElementVNode("div", { class: "mint-topbar__logo-icon" }, [createElementVNode("span", { class: "mint-topbar__logo-text" }, "M")], -1)])])) : createCommentVNode("", true)], void 0, 1)], void 0, 1)])) : createCommentVNode("", true)]),
3100
+ }, null, 8, ["icon"])) : renderSlot(_ctx.$slots, "logo", {}, () => [config.value.logo ? (openBlock(), createElementBlock("div", _hoisted_8$1, [..._cache[13] || (_cache[13] = [createElementVNode("div", { class: "mint-topbar__logo-icon" }, [createElementVNode("span", { class: "mint-topbar__logo-text" }, "M")], -1)])])) : createCommentVNode("", true)], void 0, 1)], void 0, 1)])) : createCommentVNode("", true)]),
2895
3101
  _: 3
2896
3102
  }, 8, ["to"])) : (openBlock(), createElementBlock(Fragment, { key: 2 }, [unref(isIntegrated) || _ctx.$slots.icon || _ctx.$slots.logo || pluginIcon.value || config.value.logo ? (openBlock(), createElementBlock("span", _hoisted_9$1, [unref(isIntegrated) ? (openBlock(), createBlock(PluginIcon_default, {
2897
3103
  key: 0,
@@ -2905,21 +3111,21 @@ var AppTopBar_default = /* @__PURE__ */ defineComponent({
2905
3111
  icon: pluginIcon.value,
2906
3112
  size: "topbar",
2907
3113
  variant: "solid"
2908
- }, null, 8, ["icon"])) : renderSlot(_ctx.$slots, "logo", {}, () => [config.value.logo ? (openBlock(), createElementBlock("div", _hoisted_10$1, [..._cache[13] || (_cache[13] = [createElementVNode("div", { class: "mint-topbar__logo-icon" }, [createElementVNode("span", { class: "mint-topbar__logo-text" }, "M")], -1)])])) : createCommentVNode("", true)], void 0, 1)], void 0, 1)])) : createCommentVNode("", true)], 64))]),
3114
+ }, null, 8, ["icon"])) : renderSlot(_ctx.$slots, "logo", {}, () => [config.value.logo ? (openBlock(), createElementBlock("div", _hoisted_10$1, [..._cache[14] || (_cache[14] = [createElementVNode("div", { class: "mint-topbar__logo-icon" }, [createElementVNode("span", { class: "mint-topbar__logo-text" }, "M")], -1)])])) : createCommentVNode("", true)], void 0, 1)], void 0, 1)])) : createCommentVNode("", true)], 64))]),
2909
3115
  identityName.value ? (openBlock(), createElementBlock("span", _hoisted_11$1, [createElementVNode("span", _hoisted_12$1, toDisplayString(identityName.value), 1), identitySubtitle.value ? (openBlock(), createElementBlock("span", _hoisted_13$1, toDisplayString(identitySubtitle.value), 1)) : createCommentVNode("", true)])) : createCommentVNode("", true),
2910
3116
  hasPlatformPageSelector.value ? (openBlock(), createElementBlock("span", {
2911
- key: 1,
3117
+ key: 2,
2912
3118
  ref_key: "platformPageSelectorEl",
2913
3119
  ref: platformPageSelectorEl,
2914
3120
  class: "mint-topbar__platform-page-selector",
2915
3121
  "data-onboarding": "topbar-page-selector"
2916
3122
  }, null, 512)) : hasPropPageSelector.value ? (openBlock(), createBlock(AppTopBarPageSelectorInternal_default, {
2917
- key: 2,
3123
+ key: 3,
2918
3124
  "data-onboarding": "topbar-page-selector",
2919
3125
  pages: normalizedPageSelector.value,
2920
3126
  "current-page-id": __props.currentPageSelectorId,
2921
3127
  "plugin-name": pageSelectorPluginName.value,
2922
- onSelect: _cache[0] || (_cache[0] = ($event) => emit("page-selector-select", $event))
3128
+ onSelect: _cache[1] || (_cache[1] = ($event) => emit("page-selector-select", $event))
2923
3129
  }, createSlots({ _: 2 }, [_ctx.$slots["page-selector-icon"] ? {
2924
3130
  name: "icon",
2925
3131
  fn: withCtx((slotProps) => [renderSlot(_ctx.$slots, "page-selector-icon", normalizeProps(guardReactiveProps(slotProps)))]),
@@ -2941,11 +3147,11 @@ var AppTopBar_default = /* @__PURE__ */ defineComponent({
2941
3147
  items: normalizedPillNav.value,
2942
3148
  "current-item-id": __props.pill,
2943
3149
  onSelect: handlePillSelect,
2944
- onOptionSelect: _cache[1] || (_cache[1] = (option, item) => emit("pill-option-select", option, item))
3150
+ onOptionSelect: _cache[2] || (_cache[2] = (option, item) => emit("pill-option-select", option, item))
2945
3151
  }, null, 8, ["items", "current-item-id"])) : createCommentVNode("", true)])])) : createCommentVNode("", true),
2946
- createElementVNode("div", _hoisted_19$1, [
2947
- config.value.standaloneLabel !== false && isStandalone.value ? (openBlock(), createElementBlock("span", _hoisted_20$1, toDisplayString(config.value.standaloneLabel), 1)) : createCommentVNode("", true),
2948
- showExperiment.value || __props.job !== void 0 || runSlotJoined.value ? (openBlock(), createElementBlock("div", {
3152
+ createElementVNode("div", _hoisted_19$1, [hasContext.value ? (openBlock(), createElementBlock("div", _hoisted_20$1, [
3153
+ showStandaloneBadge.value ? (openBlock(), createElementBlock("span", _hoisted_21$1, toDisplayString(config.value.standaloneLabel), 1)) : createCommentVNode("", true),
3154
+ showRunSlot.value ? (openBlock(), createElementBlock("div", {
2949
3155
  key: 1,
2950
3156
  class: normalizeClass(["mint-topbar__run-slot", { "mint-topbar__run-slot--joined": runSlotJoined.value }]),
2951
3157
  "data-onboarding": "topbar-run"
@@ -2954,11 +3160,11 @@ var AppTopBar_default = /* @__PURE__ */ defineComponent({
2954
3160
  ...unref(appExperiment).popover.value,
2955
3161
  showSave: false
2956
3162
  } : unref(appExperiment).popover.value, {
2957
- onSelect: _cache[2] || (_cache[2] = ($event) => unref(appExperiment).openModal()),
2958
- onSave: _cache[3] || (_cache[3] = ($event) => unref(appExperiment).handleSave()),
2959
- onDetach: _cache[4] || (_cache[4] = ($event) => unref(appExperiment).handleDetach())
3163
+ onSelect: _cache[3] || (_cache[3] = ($event) => unref(appExperiment).openModal()),
3164
+ onSave: _cache[4] || (_cache[4] = ($event) => unref(appExperiment).handleSave()),
3165
+ onDetach: _cache[5] || (_cache[5] = ($event) => unref(appExperiment).handleDetach())
2960
3166
  }), null, 16)) : createCommentVNode("", true),
2961
- createElementVNode("span", _hoisted_21$1, toDisplayString(__props.job ? JOB_STATUS_TEXT[__props.job.status] : ""), 1),
3167
+ createElementVNode("span", _hoisted_22$1, toDisplayString(__props.job ? JOB_STATUS_TEXT[__props.job.status] : ""), 1),
2962
3168
  createVNode(Transition, {
2963
3169
  name: "mint-topbar-job",
2964
3170
  mode: "out-in",
@@ -2974,48 +3180,110 @@ var AppTopBar_default = /* @__PURE__ */ defineComponent({
2974
3180
  "aria-label": jobName.value,
2975
3181
  "aria-expanded": __props.jobsOpen,
2976
3182
  "aria-controls": __props.jobsPanelId,
2977
- onClick: _cache[5] || (_cache[5] = ($event) => emit("job-click"))
3183
+ onClick: _cache[6] || (_cache[6] = ($event) => emit("job-click"))
2978
3184
  }, [(openBlock(), createBlock(resolveDynamicComponent(JOB_ICONS[__props.job.status]), {
2979
3185
  class: normalizeClass(["mint-topbar__job-icon", { "mint-topbar__job-icon--spin": __props.job.status === "running" || __props.job.status === "queued" }]),
2980
3186
  size: 14,
2981
3187
  "aria-hidden": "true"
2982
- }, null, 8, ["class"])), jobPercent.value != null ? (openBlock(), createElementBlock("span", _hoisted_23$1, [createElementVNode("span", { style: normalizeStyle({ width: `${jobPercent.value}%` }) }, null, 4)])) : createCommentVNode("", true)], 10, _hoisted_22$1)) : __props.job === null ? (openBlock(), createElementBlock("button", {
3188
+ }, null, 8, ["class"])), jobPercent.value != null ? (openBlock(), createElementBlock("span", _hoisted_24$1, [createElementVNode("span", { style: normalizeStyle({ width: `${jobPercent.value}%` }) }, null, 4)])) : createCommentVNode("", true)], 10, _hoisted_23$1)) : __props.job === null ? (openBlock(), createElementBlock("button", {
2983
3189
  key: "idle",
2984
3190
  type: "button",
2985
3191
  class: "mint-topbar__job mint-topbar__job--idle",
2986
- "aria-label": __props.jobsDone ? `Jobs, ${__props.jobsDone} completed` : void 0,
3192
+ "aria-label": __props.jobsDone ? `Jobs, ${__props.jobsDone} completed` : "Jobs",
3193
+ title: "Jobs",
2987
3194
  "aria-expanded": __props.jobsOpen,
2988
3195
  "aria-controls": __props.jobsPanelId,
2989
- onClick: _cache[6] || (_cache[6] = ($event) => emit("job-click"))
3196
+ onClick: _cache[7] || (_cache[7] = ($event) => emit("job-click"))
2990
3197
  }, [
2991
3198
  createVNode(unref(ListChecks), {
2992
3199
  class: "mint-topbar__job-icon",
2993
3200
  size: 14,
2994
3201
  "aria-hidden": "true"
2995
3202
  }),
2996
- _cache[14] || (_cache[14] = createElementVNode("span", { class: "mint-topbar__job-label" }, "Jobs", -1)),
2997
- __props.jobsDone ? (openBlock(), createElementBlock("span", _hoisted_25$1, toDisplayString(__props.jobsDone), 1)) : createCommentVNode("", true)
2998
- ], 8, _hoisted_24$1)) : createCommentVNode("", true)]),
3203
+ _cache[15] || (_cache[15] = createElementVNode("span", { class: "mint-topbar__job-label" }, "Jobs", -1)),
3204
+ __props.jobsDone ? (openBlock(), createElementBlock("span", _hoisted_26$1, toDisplayString(__props.jobsDone), 1)) : createCommentVNode("", true)
3205
+ ], 8, _hoisted_25$1)) : createCommentVNode("", true)]),
2999
3206
  _: 1
3000
3207
  })
3001
3208
  ], 2)) : createCommentVNode("", true),
3002
- renderSlot(_ctx.$slots, "actions"),
3003
3209
  unref(onboarding)?.enabled.value ? (openBlock(), createBlock(AppTopBarOnboardingInternal_default, {
3004
3210
  key: 2,
3005
3211
  state: unref(onboarding)
3006
3212
  }, null, 8, ["state"])) : createCommentVNode("", true),
3007
- config.value.themeToggle ? (openBlock(), createBlock(ThemeToggle_default, {
3213
+ (openBlock(true), createElementBlock(Fragment, null, renderList(visibleActions.value, (action) => {
3214
+ return openBlock(), createElementBlock(Fragment, { key: action.id }, [action.icon ? (openBlock(), createElementBlock("button", {
3215
+ key: 0,
3216
+ type: "button",
3217
+ class: "mint-topbar__icon-btn",
3218
+ "aria-label": action.label,
3219
+ title: action.title ?? action.label,
3220
+ disabled: action.disabled || action.loading,
3221
+ "aria-busy": action.loading || void 0,
3222
+ "data-action": action.id,
3223
+ onClick: ($event) => action.onSelect()
3224
+ }, [action.loading ? (openBlock(), createBlock(unref(LoaderCircle), {
3225
+ key: 0,
3226
+ class: "mint-topbar__icon-btn-icon mint-topbar__job-icon--spin",
3227
+ "aria-hidden": "true"
3228
+ })) : (openBlock(), createBlock(LucideIconInternal_default, {
3229
+ key: 1,
3230
+ name: action.icon,
3231
+ size: 16
3232
+ }, null, 8, ["name"])), action.dot ? (openBlock(), createElementBlock("span", {
3233
+ key: 2,
3234
+ class: normalizeClass(["mint-topbar__icon-btn-dot", `mint-topbar__icon-btn-dot--${action.dot}`]),
3235
+ "aria-hidden": "true"
3236
+ }, null, 2)) : createCommentVNode("", true)], 8, _hoisted_27$1)) : (openBlock(), createBlock(BaseButton_default, {
3237
+ key: 1,
3238
+ variant: "secondary",
3239
+ size: "sm",
3240
+ title: action.title,
3241
+ loading: action.loading,
3242
+ disabled: action.disabled,
3243
+ "data-action": action.id,
3244
+ onClick: ($event) => action.onSelect()
3245
+ }, {
3246
+ default: withCtx(() => [createTextVNode(toDisplayString(action.label), 1)]),
3247
+ _: 2
3248
+ }, 1032, [
3249
+ "title",
3250
+ "loading",
3251
+ "disabled",
3252
+ "data-action",
3253
+ "onClick"
3254
+ ]))], 64);
3255
+ }), 128)),
3256
+ overflowMenuItems.value.length ? (openBlock(), createBlock(ActionMenu_default, {
3008
3257
  key: 3,
3009
- size: "sm"
3010
- })) : createCommentVNode("", true),
3011
- showSettings.value ? (openBlock(), createElementBlock("button", {
3012
- key: 4,
3258
+ label: "More actions",
3259
+ items: overflowMenuItems.value,
3260
+ onSelect: selectOverflowAction
3261
+ }, {
3262
+ trigger: withCtx(({ open, toggle, keydown }) => [createElementVNode("button", {
3263
+ type: "button",
3264
+ class: "mint-topbar__icon-btn",
3265
+ "aria-label": "More actions",
3266
+ title: "More actions",
3267
+ "aria-haspopup": "menu",
3268
+ "aria-expanded": open,
3269
+ onClick: toggle,
3270
+ onKeydown: keydown
3271
+ }, [createVNode(unref(Ellipsis), {
3272
+ class: "mint-topbar__icon-btn-icon",
3273
+ "aria-hidden": "true"
3274
+ })], 40, _hoisted_28$1)]),
3275
+ _: 1
3276
+ }, 8, ["items"])) : createCommentVNode("", true),
3277
+ _ctx.$slots.actions ? (openBlock(), createElementBlock("span", _hoisted_29$1, [renderSlot(_ctx.$slots, "actions")])) : createCommentVNode("", true)
3278
+ ])) : createCommentVNode("", true), createElementVNode("div", _hoisted_30$1, [
3279
+ createVNode(ThemeToggle_default, { size: "sm" }),
3280
+ createElementVNode("button", {
3013
3281
  type: "button",
3014
3282
  class: "mint-topbar__settings-btn",
3015
3283
  "aria-label": "Open settings",
3016
3284
  "data-onboarding": "topbar-settings",
3017
- onClick: _cache[7] || (_cache[7] = ($event) => settingsOpen.value = true)
3018
- }, [..._cache[15] || (_cache[15] = [createElementVNode("svg", {
3285
+ onClick: _cache[8] || (_cache[8] = ($event) => settingsOpen.value = true)
3286
+ }, [..._cache[16] || (_cache[16] = [createElementVNode("svg", {
3019
3287
  class: "mint-topbar__settings-icon",
3020
3288
  viewBox: "0 0 24 24",
3021
3289
  fill: "none",
@@ -3027,14 +3295,14 @@ var AppTopBar_default = /* @__PURE__ */ defineComponent({
3027
3295
  cx: "12",
3028
3296
  cy: "12",
3029
3297
  r: "3"
3030
- })], -1)])])) : createCommentVNode("", true),
3298
+ })], -1)])]),
3031
3299
  renderSlot(_ctx.$slots, "account")
3032
- ])
3033
- ])], 2),
3034
- showSettings.value && settingsOpen.value ? (openBlock(), createBlock(unref(SettingsModal), {
3300
+ ])])
3301
+ ], 2)], 2),
3302
+ settingsOpen.value ? (openBlock(), createBlock(unref(SettingsModal), {
3035
3303
  key: 0,
3036
3304
  open: settingsOpen.value,
3037
- "onUpdate:open": _cache[8] || (_cache[8] = ($event) => settingsOpen.value = $event),
3305
+ "onUpdate:open": _cache[9] || (_cache[9] = ($event) => settingsOpen.value = $event),
3038
3306
  title: settingsConfig.value?.title,
3039
3307
  tabs: normalizedSettingsTabs.value,
3040
3308
  "show-appearance": settingsConfig.value?.showAppearance ?? true,
@@ -3044,7 +3312,7 @@ var AppTopBar_default = /* @__PURE__ */ defineComponent({
3044
3312
  spec: settingsConfig.value?.spec,
3045
3313
  values: settingsConfig.value?.values,
3046
3314
  "user-type": settingsConfig.value?.userType,
3047
- "onUpdate:values": _cache[9] || (_cache[9] = ($event) => emit("settings-values-change", $event))
3315
+ "onUpdate:values": _cache[10] || (_cache[10] = ($event) => emit("settings-values-change", $event))
3048
3316
  }, createSlots({
3049
3317
  appearance: withCtx(() => [renderSlot(_ctx.$slots, "settings-appearance")]),
3050
3318
  _: 2
@@ -3065,7 +3333,7 @@ var AppTopBar_default = /* @__PURE__ */ defineComponent({
3065
3333
  "values",
3066
3334
  "user-type"
3067
3335
  ])) : createCommentVNode("", true),
3068
- unref(appExperiment) && !isStandalone.value && canBindExperiment.value && unref(appExperiment).selectorModal.value.open ? (openBlock(), createBlock(unref(ExperimentSelectorModal), mergeProps({ key: 1 }, unref(appExperiment).selectorModal.value, { "onUpdate:open": _cache[10] || (_cache[10] = ($event) => $event ? unref(appExperiment).openModal() : unref(appExperiment).closeModal()) }), null, 16)) : createCommentVNode("", true)
3336
+ unref(appExperiment) && !isStandalone.value && canBindExperiment.value && unref(appExperiment).selectorModal.value.open ? (openBlock(), createBlock(unref(ExperimentSelectorModal), mergeProps({ key: 1 }, unref(appExperiment).selectorModal.value, { "onUpdate:open": _cache[11] || (_cache[11] = ($event) => $event ? unref(appExperiment).openModal() : unref(appExperiment).closeModal()) }), null, 16)) : createCommentVNode("", true)
3069
3337
  ], 64);
3070
3338
  };
3071
3339
  }
@@ -4534,6 +4802,6 @@ var AppSidebar_default = /* @__PURE__ */ defineComponent({
4534
4802
  }
4535
4803
  });
4536
4804
  //#endregion
4537
- export { controlValuesToComponentBindingsById as A, usePluginWorkspace as C, useControlSchema as D, getControlDefaults as E, getDefaultControlView as F, CollapsibleCard_default as I, ThemeToggle_default as L, controlsTo as M, controlsToFormSchema as N, controlBindings as O, controlsToSettingsSchema as P, useTheme as R, AppLayout_default as S, defineControls as T, provideOnboarding as _, pickExistingRecordKeys as a, normalizeItemInput as b, valuesEqual as c, useForm as d, AppTopBar_default as f, defineOnboarding as g, ONBOARDING_KEY as h, formSchemaFieldNames as i, controlValuesToComponentProps as j, controlValuesToComponentBindings as k, useFormBuilder as l, ANCHOR_WAIT_MS as m, FormSchemaInternal_default as n, pickRecordKeys as o, providePluginIdentity as p, FormFieldRendererInternal_default as r, recordValuesEqualForKeys as s, AppSidebar_default as t, evaluateCondition as u, useOnboarding as v, defineControlComponentBindings as w, normalizeLabelItemInput as x, PluginIcon_default as y };
4805
+ export { controlValuesToComponentBindings as A, warnDeprecatedOnce as C, getControlDefaults as D, defineControls as E, controlsToSettingsSchema as F, getDefaultControlView as I, CollapsibleCard_default as L, controlValuesToComponentProps as M, controlsTo as N, useControlSchema as O, controlsToFormSchema as P, ThemeToggle_default as R, AppLayout_default as S, defineControlComponentBindings as T, provideOnboarding as _, pickExistingRecordKeys as a, normalizeItemInput as b, valuesEqual as c, useForm as d, AppTopBar_default as f, defineOnboarding as g, ONBOARDING_KEY as h, formSchemaFieldNames as i, controlValuesToComponentBindingsById as j, controlBindings as k, useFormBuilder as l, ANCHOR_WAIT_MS as m, FormSchemaInternal_default as n, pickRecordKeys as o, providePluginIdentity as p, FormFieldRendererInternal_default as r, recordValuesEqualForKeys as s, AppSidebar_default as t, evaluateCondition as u, useOnboarding as v, usePluginWorkspace as w, normalizeLabelItemInput as x, PluginIcon_default as y, useTheme as z };
4538
4806
 
4539
- //# sourceMappingURL=AppSidebar-C4qQLHcH.js.map
4807
+ //# sourceMappingURL=AppSidebar-C-Vq5x4I.js.map