@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.
- package/dist/{AlertBox-CexONPhA.js → AlertBox-Cai0w7gF.js} +3 -3
- package/dist/{AlertBox-CexONPhA.js.map → AlertBox-Cai0w7gF.js.map} +1 -1
- package/dist/{AppSidebar-C4qQLHcH.js → AppSidebar-C-Vq5x4I.js} +361 -93
- package/dist/AppSidebar-C-Vq5x4I.js.map +1 -0
- package/dist/{ConfirmDialog-D9QXFpsy.js → ConfirmDialog-BjFsOpBe.js} +2 -2
- package/dist/{ConfirmDialog-D9QXFpsy.js.map → ConfirmDialog-BjFsOpBe.js.map} +1 -1
- package/dist/{ExperimentPopover-DyjoXwry.js → ExperimentPopover-DYy_s0kI.js} +21 -20
- package/dist/ExperimentPopover-DYy_s0kI.js.map +1 -0
- package/dist/{ExperimentSelectorModal-CUkKmgfr.js → ExperimentSelectorModal-Bfh5bdkv.js} +5 -5
- package/dist/{ExperimentSelectorModal-CUkKmgfr.js.map → ExperimentSelectorModal-Bfh5bdkv.js.map} +1 -1
- package/dist/{SegmentedControl-C-sckoJZ.js → SegmentedControl-B8KgyOjd.js} +2 -2
- package/dist/{SegmentedControl-C-sckoJZ.js.map → SegmentedControl-B8KgyOjd.js.map} +1 -1
- package/dist/{SettingsModal-B1ltysmg.js → SettingsModal-DwfrD1ER.js} +7 -7
- package/dist/{SettingsModal-B1ltysmg.js.map → SettingsModal-DwfrD1ER.js.map} +1 -1
- package/dist/__tests__/components/AppTopBarCompact.test.d.ts +1 -0
- package/dist/__tests__/components/AppTopBarCompactReset.test.d.ts +1 -0
- package/dist/__tests__/components/AutoGroupModal.experimentLoad.test.d.ts +1 -0
- package/dist/components/AppTopBar.compact.d.ts +5 -0
- package/dist/components/AppTopBar.vue.d.ts +17 -17
- package/dist/components/PluginWorkspaceView.vue.d.ts +4 -0
- package/dist/components/internal/AppTopBarPageSelectorInternal.vue.d.ts +2 -2
- package/dist/components/internal/LucideIconInternal.vue.d.ts +17 -0
- package/dist/composables/appLayoutSidebar.d.ts +9 -0
- package/dist/composables/usePluginWorkspace.d.ts +2 -0
- package/dist/composables/useVersionedSave.d.ts +5 -2
- package/dist/{controlSchemaModel-C_XqpkgE.js → controlSchemaModel-BtFNZj8t.js} +2 -2
- package/dist/{controlSchemaModel-C_XqpkgE.js.map → controlSchemaModel-BtFNZj8t.js.map} +1 -1
- package/dist/{data-CgIcnf9D.js → data-CJztFns8.js} +31 -15
- package/dist/{data-CgIcnf9D.js.map → data-CJztFns8.js.map} +1 -1
- package/dist/data.js +8 -8
- package/dist/{experimentStatus-DCn2QKG7.js → experimentStatus-Deokk7Br.js} +2 -2
- package/dist/{experimentStatus-DCn2QKG7.js.map → experimentStatus-Deokk7Br.js.map} +1 -1
- package/dist/index.js +14 -14
- package/dist/{install-DmyjbTJ5.js → install-Bk02tJ5M.js} +14 -15
- package/dist/{install-DmyjbTJ5.js.map → install-Bk02tJ5M.js.map} +1 -1
- package/dist/install.js +1 -1
- package/dist/{lab-BcX5JBSY.js → lab-BYhb_cJI.js} +22 -14
- package/dist/lab-BYhb_cJI.js.map +1 -0
- package/dist/lab.js +4 -4
- package/dist/{records-BAymyHAn.js → records-GtiVMlTQ.js} +198 -62
- package/dist/records-GtiVMlTQ.js.map +1 -0
- package/dist/{runtime-CjfAxufu.js → runtime-aZPUPxoB.js} +40 -19
- package/dist/runtime-aZPUPxoB.js.map +1 -0
- package/dist/runtime.js +6 -6
- package/dist/{shell-XDqDu_UD.js → shell-Bk9mD4Lc.js} +5 -5
- package/dist/{shell-XDqDu_UD.js.map → shell-Bk9mD4Lc.js.map} +1 -1
- package/dist/shell.js +5 -5
- package/dist/styles.css +138 -13
- package/dist/types/components.d.ts +22 -2
- package/dist/types/index.d.ts +1 -1
- package/dist/{useDropdownState-uFIz6Yv8.js → useDropdownState-CcBzUYZ6.js} +14 -5
- package/dist/useDropdownState-CcBzUYZ6.js.map +1 -0
- package/dist/{useExperimentSamples-DEDAKa2E.js → useExperimentSamples-CpNXvpUn.js} +3 -3
- package/dist/{useExperimentSamples-DEDAKa2E.js.map → useExperimentSamples-CpNXvpUn.js.map} +1 -1
- package/dist/{useListReorder-W1bzK_bo.js → useListReorder-Bp4EAI2w.js} +3 -3
- package/dist/{useListReorder-W1bzK_bo.js.map → useListReorder-Bp4EAI2w.js.map} +1 -1
- package/dist/{useRackEditor-Bmtuo0aj.js → useRackEditor-i2bdPUFf.js} +8 -8
- package/dist/{useRackEditor-Bmtuo0aj.js.map → useRackEditor-i2bdPUFf.js.map} +1 -1
- package/dist/{useRealtime-jOetF2mM.js → useRealtime-BLQEjbuq.js} +3 -3
- package/dist/{useRealtime-jOetF2mM.js.map → useRealtime-BLQEjbuq.js.map} +1 -1
- package/dist/useRequest-CXyPw3eh.js +76 -0
- package/dist/useRequest-CXyPw3eh.js.map +1 -0
- package/dist/utils/deprecation.d.ts +2 -0
- package/dist/utils/lucideIcon.d.ts +4 -0
- package/package.json +1 -1
- package/src/__tests__/components/AppTopBar.test.ts +102 -20
- package/src/__tests__/components/AppTopBarCompact.test.ts +65 -0
- package/src/__tests__/components/AppTopBarCompactReset.test.ts +24 -0
- package/src/__tests__/components/AutoGroupModal.experimentLoad.test.ts +58 -0
- package/src/__tests__/components/BaseModal.test.ts +33 -2
- package/src/__tests__/components/PluginWorkspaceView.test.ts +20 -1
- package/src/__tests__/composables/useJobCenter.test.ts +35 -0
- package/src/__tests__/composables/useVersionedSave.test.ts +71 -6
- package/src/__tests__/styles/menusShellRefresh.test.ts +10 -0
- package/src/components/AppLayout.story.vue +5 -5
- package/src/components/AppLayout.vue +13 -1
- package/src/components/AppTopBar.compact.ts +60 -0
- package/src/components/AppTopBar.story.vue +39 -14
- package/src/components/AppTopBar.vue +222 -89
- package/src/components/BaseModal.vue +16 -5
- package/src/components/ExperimentPopover.vue +1 -1
- package/src/components/GeneratedPluginView.vue +0 -1
- package/src/components/PluginWorkspaceView.vue +10 -1
- package/src/components/internal/AppTopBarPageSelectorInternal.vue +12 -0
- package/src/components/internal/AutoGroupModalInternal.vue +14 -3
- package/src/components/internal/LucideIconInternal.vue +23 -0
- package/src/composables/appLayoutSidebar.ts +11 -0
- package/src/composables/useJobCenter.ts +21 -1
- package/src/composables/usePluginWorkspace.ts +15 -4
- package/src/composables/useVersionedSave.ts +32 -7
- package/src/styles/components/app-layout.css +5 -0
- package/src/styles/components/app-top-bar.css +130 -9
- package/src/types/components.ts +23 -2
- package/src/types/index.ts +1 -0
- package/src/utils/deprecation.ts +8 -0
- package/src/utils/lucideIcon.ts +25 -0
- package/src/utils/lucideIconIndex.d.ts +2 -0
- package/dist/AppSidebar-C4qQLHcH.js.map +0 -1
- package/dist/ExperimentPopover-DyjoXwry.js.map +0 -1
- package/dist/lab-BcX5JBSY.js.map +0 -1
- package/dist/records-BAymyHAn.js.map +0 -1
- package/dist/runtime-CjfAxufu.js.map +0 -1
- package/dist/useDropdownState-uFIz6Yv8.js.map +0 -1
- package/dist/useRequest-D9-3BS-3.js +0 -215
- package/dist/useRequest-D9-3BS-3.js.map +0 -1
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { i as useEventListener, o as __exportAll, t as useDropdownState } from "./useDropdownState-
|
|
1
|
+
import { i as useEventListener, o as __exportAll, t as useDropdownState } from "./useDropdownState-CcBzUYZ6.js";
|
|
2
2
|
import { i as AuthenticationRequiredError, o as useApi } from "./experiment-DyO54FQB.js";
|
|
3
|
-
import {
|
|
4
|
-
import { A as useJobsEndpoint, D as _plugin_vue_export_helper_default, E as GeneratedPathInput_default, M as usePlatform, O as GENERATED_JOBS_API_KEY, R as definePluginWorkspaceView, _ as getTypeDefault, g as getFieldRegistryEntry, h as replaceRecord, k as createGeneratedAnalysisTransport } from "./useListReorder-
|
|
5
|
-
import { r as LoadingSpinner_default, t as AlertBox_default } from "./AlertBox-
|
|
6
|
-
import { D as SectionCard_default, O as DataFrame_default, T as WellPlate_default, a as GeneratedPlotlyResult_default, b as PlateEditor_default, c as downloadEndpoint, d as useEventStream, f as useSettingsEndpoint, i as GeneratedResultRenderer_default, l as pluginFormDataFromPayload, m as resolvePluginBaseUrl, n as ScheduleCalendar_default, o as createClient, p as buildEndpointUrl, t as useRackEditor, u as uploadEndpoint, v as DoseCalculator_default } from "./useRackEditor-
|
|
7
|
-
import { A as
|
|
8
|
-
import { n as isControlModelBinding } from "./controlSchemaModel-
|
|
9
|
-
import { i as JobsStatusTray_default, n as subscribeRealtime, r as useRealtime, t as currentPresence } from "./useRealtime-
|
|
3
|
+
import { R as EmptyState_default, d as isActiveJobStatus, f as isTerminalJobStatus, g as resolveJobCapabilities, h as normalizeJobState, m as normalizeJobPercent, o as resolveCurrentPluginId, p as jobStatusLabel, t as isRecord, v as useAppExperiment } from "./records-GtiVMlTQ.js";
|
|
4
|
+
import { A as useJobsEndpoint, D as _plugin_vue_export_helper_default, E as GeneratedPathInput_default, M as usePlatform, O as GENERATED_JOBS_API_KEY, R as definePluginWorkspaceView, _ as getTypeDefault, g as getFieldRegistryEntry, h as replaceRecord, k as createGeneratedAnalysisTransport } from "./useListReorder-Bp4EAI2w.js";
|
|
5
|
+
import { r as LoadingSpinner_default, t as AlertBox_default } from "./AlertBox-Cai0w7gF.js";
|
|
6
|
+
import { D as SectionCard_default, O as DataFrame_default, T as WellPlate_default, a as GeneratedPlotlyResult_default, b as PlateEditor_default, c as downloadEndpoint, d as useEventStream, f as useSettingsEndpoint, i as GeneratedResultRenderer_default, l as pluginFormDataFromPayload, m as resolvePluginBaseUrl, n as ScheduleCalendar_default, o as createClient, p as buildEndpointUrl, t as useRackEditor, u as uploadEndpoint, v as DoseCalculator_default } from "./useRackEditor-i2bdPUFf.js";
|
|
7
|
+
import { A as controlValuesToComponentBindings, C as warnDeprecatedOnce, D as getControlDefaults, E as defineControls, I as getDefaultControlView, M as controlValuesToComponentProps, N as controlsTo, O as useControlSchema, S as AppLayout_default, T as defineControlComponentBindings, d as useForm, f as AppTopBar_default, j as controlValuesToComponentBindingsById, k as controlBindings, l as useFormBuilder, p as providePluginIdentity, t as AppSidebar_default, u as evaluateCondition, w as usePluginWorkspace } from "./AppSidebar-C-Vq5x4I.js";
|
|
8
|
+
import { n as isControlModelBinding } from "./controlSchemaModel-BtFNZj8t.js";
|
|
9
|
+
import { i as JobsStatusTray_default, n as subscribeRealtime, r as useRealtime, t as currentPresence } from "./useRealtime-BLQEjbuq.js";
|
|
10
10
|
import { Fragment, Teleport, TransitionGroup, computed, createBlock, createCommentVNode, createElementBlock, createElementVNode, createSlots, createTextVNode, createVNode, defineComponent, getCurrentScope, guardReactiveProps, mergeProps, normalizeClass, normalizeProps, normalizeStyle, onMounted, onScopeDispose, onUnmounted, openBlock, provide, reactive, readonly, ref, renderList, renderSlot, resolveDynamicComponent, shallowRef, toDisplayString, toHandlers, toValue, unref, useId, useSlots, useTemplateRef, watch, withCtx, withModifiers } from "vue";
|
|
11
11
|
import { ChartColumn, Eye, FlaskConical, Pencil, RefreshCw } from "lucide-vue-next";
|
|
12
12
|
//#region src/composables/useToast.ts
|
|
@@ -369,6 +369,11 @@ function useJobCenter(options = {}) {
|
|
|
369
369
|
watch([source, ownActiveJobs], ([currentSource, now], [previousSource, before]) => {
|
|
370
370
|
if (currentSource !== previousSource) {
|
|
371
371
|
justFinished.value = null;
|
|
372
|
+
if (previousSource) {
|
|
373
|
+
hasBaseline = false;
|
|
374
|
+
awaitingLoad = false;
|
|
375
|
+
if (jobs.value.length > 0) takeBaseline();
|
|
376
|
+
}
|
|
372
377
|
return;
|
|
373
378
|
}
|
|
374
379
|
const nowIds = new Set(now.map((job) => job.job_id));
|
|
@@ -462,19 +467,31 @@ function useJobCenter(options = {}) {
|
|
|
462
467
|
if (active && generation === requestGeneration) isLoading.value = false;
|
|
463
468
|
}
|
|
464
469
|
}
|
|
470
|
+
const cancelling = /* @__PURE__ */ new Map();
|
|
471
|
+
watch(jobs, (list) => {
|
|
472
|
+
for (const [jobId, status] of cancelling) {
|
|
473
|
+
if (list.find((job) => job.job_id === jobId)?.status === status) continue;
|
|
474
|
+
cancelling.delete(jobId);
|
|
475
|
+
setPending(jobId, false);
|
|
476
|
+
}
|
|
477
|
+
});
|
|
465
478
|
async function cancelJob(job) {
|
|
466
479
|
const sourceCancel = source.value?.cancel;
|
|
467
480
|
if (!job.can_cancel || !sourceCancel || pendingJobIds.value.has(job.job_id)) return false;
|
|
468
481
|
setPending(job.job_id, true);
|
|
469
482
|
error.value = null;
|
|
483
|
+
let cancelled = false;
|
|
470
484
|
try {
|
|
471
485
|
await sourceCancel(job.job_id);
|
|
486
|
+
cancelled = true;
|
|
472
487
|
return active;
|
|
473
488
|
} catch (cause) {
|
|
474
489
|
if (active) error.value = errorMessage(cause, "Failed to cancel job");
|
|
475
490
|
return false;
|
|
476
491
|
} finally {
|
|
477
|
-
|
|
492
|
+
const status = jobs.value.find((listed) => listed.job_id === job.job_id)?.status;
|
|
493
|
+
if (cancelled && status === job.status) cancelling.set(job.job_id, status);
|
|
494
|
+
else if (active) setPending(job.job_id, false);
|
|
478
495
|
}
|
|
479
496
|
}
|
|
480
497
|
async function deleteJob(job) {
|
|
@@ -917,6 +934,7 @@ var PluginWorkspaceView_default = /* @__PURE__ */ defineComponent({
|
|
|
917
934
|
const props = __props;
|
|
918
935
|
const emit = __emit;
|
|
919
936
|
const slots = useSlots();
|
|
937
|
+
if (slots.topbar) warnDeprecatedOnce("workspace.slot.topbar", "PluginWorkspaceView #topbar is deprecated: configure spec.topBar and give pages icons. It is removed in 2.0.");
|
|
920
938
|
if (props.spec.experiment) {
|
|
921
939
|
const save = props.spec.save;
|
|
922
940
|
useAppExperiment({
|
|
@@ -932,7 +950,7 @@ var PluginWorkspaceView_default = /* @__PURE__ */ defineComponent({
|
|
|
932
950
|
function handleJobSelect(job) {
|
|
933
951
|
emit("job-select", job);
|
|
934
952
|
}
|
|
935
|
-
const { shell, sidebar, controls, handleControlValuesUpdate, handlePillSelect } = usePluginWorkspace({
|
|
953
|
+
const { shell, sidebar, controls, handleControlValuesUpdate, handlePillSelect, handleSidebarCollapsedUpdate } = usePluginWorkspace({
|
|
936
954
|
props,
|
|
937
955
|
slots,
|
|
938
956
|
emit
|
|
@@ -953,10 +971,10 @@ var PluginWorkspaceView_default = /* @__PURE__ */ defineComponent({
|
|
|
953
971
|
"jobs-done": unref(jobCenter)?.completedCount.value,
|
|
954
972
|
"jobs-open": unref(jobCenter)?.isOpen.value,
|
|
955
973
|
"jobs-panel-id": unref(jobCenter)?.panelId,
|
|
956
|
-
onJobClick: _cache[
|
|
974
|
+
onJobClick: _cache[1] || (_cache[1] = ($event) => unref(jobCenter)?.handleTopBarClick(handleJobSelect)),
|
|
957
975
|
onPillSelect: unref(handlePillSelect),
|
|
958
|
-
onPillOptionSelect: _cache[
|
|
959
|
-
onSettingsValuesChange: _cache[
|
|
976
|
+
onPillOptionSelect: _cache[2] || (_cache[2] = (option, item) => emit("pill-option-select", option, item)),
|
|
977
|
+
onSettingsValuesChange: _cache[3] || (_cache[3] = ($event) => emit("settings-values-change", $event))
|
|
960
978
|
}, createSlots({
|
|
961
979
|
default: withCtx(() => [
|
|
962
980
|
createVNode(WorkspaceControlsInternal_default, { controls: unref(controls) }, {
|
|
@@ -988,9 +1006,9 @@ var PluginWorkspaceView_default = /* @__PURE__ */ defineComponent({
|
|
|
988
1006
|
fn: withCtx((scope) => [renderSlot(_ctx.$slots, "sidebar", normalizeProps(guardReactiveProps(scope)), () => [createVNode(WorkspaceSidebarInternal_default, {
|
|
989
1007
|
sidebar: unref(sidebar),
|
|
990
1008
|
"onUpdate:values": unref(handleControlValuesUpdate),
|
|
991
|
-
"onUpdate:collapsed":
|
|
1009
|
+
"onUpdate:collapsed": unref(handleSidebarCollapsedUpdate),
|
|
992
1010
|
"onUpdate:toggle": handleToggle,
|
|
993
|
-
onSectionAction: _cache[
|
|
1011
|
+
onSectionAction: _cache[0] || (_cache[0] = (sectionId, actionId) => emit("section-action", sectionId, actionId)),
|
|
994
1012
|
onFormSubmit: handleFormSubmit,
|
|
995
1013
|
onFormCancel: handleFormCancel
|
|
996
1014
|
}, createSlots({ _: 2 }, [renderList(unref(sidebar).slotNames, (slotName) => {
|
|
@@ -998,7 +1016,11 @@ var PluginWorkspaceView_default = /* @__PURE__ */ defineComponent({
|
|
|
998
1016
|
name: slotName,
|
|
999
1017
|
fn: withCtx((slotProps) => [renderSlot(_ctx.$slots, slotName, normalizeProps(guardReactiveProps(slotProps ?? {})))])
|
|
1000
1018
|
};
|
|
1001
|
-
})]), 1032, [
|
|
1019
|
+
})]), 1032, [
|
|
1020
|
+
"sidebar",
|
|
1021
|
+
"onUpdate:values",
|
|
1022
|
+
"onUpdate:collapsed"
|
|
1023
|
+
])])]),
|
|
1002
1024
|
key: "1"
|
|
1003
1025
|
} : void 0
|
|
1004
1026
|
]), 1032, [
|
|
@@ -1287,7 +1309,6 @@ var GeneratedPluginView_default = /*#__PURE__*/ _plugin_vue_export_helper_defaul
|
|
|
1287
1309
|
topBar: {
|
|
1288
1310
|
variant: "card",
|
|
1289
1311
|
pills: pillNav.value,
|
|
1290
|
-
themeToggle: true,
|
|
1291
1312
|
settings: false,
|
|
1292
1313
|
standaloneLabel: props.showStandaloneLabel ? "Standalone" : false
|
|
1293
1314
|
},
|
|
@@ -1399,7 +1420,7 @@ var GeneratedPluginView_default = /*#__PURE__*/ _plugin_vue_export_helper_defaul
|
|
|
1399
1420
|
]);
|
|
1400
1421
|
};
|
|
1401
1422
|
}
|
|
1402
|
-
}), [["__scopeId", "data-v-
|
|
1423
|
+
}), [["__scopeId", "data-v-7ba9e342"]]);
|
|
1403
1424
|
//#endregion
|
|
1404
1425
|
//#region src/components/internal/PlateEditorBindingInternal.vue
|
|
1405
1426
|
var PlateEditorBindingInternal_default = /* @__PURE__ */ defineComponent({
|
|
@@ -1892,4 +1913,4 @@ var runtime_exports = /* @__PURE__ */ __exportAll({
|
|
|
1892
1913
|
//#endregion
|
|
1893
1914
|
export { useToast as _, ComponentBindingRenderer_default as a, generatedJobFormSchema as c, AppContainer_default as d, PluginWorkspaceView_default as f, AppToastContainer_default as g, useJobCenter as h, RuntimeUpdateNotice_default as i, normalizeGeneratedJobInput as l, combinePluginJobSources as m, PresenceAvatars_default as n, GeneratedPluginView_default as o, useControlWorkspace as p, usePresence as r, generatedJobDefaults as s, runtime_exports as t, Avatar_default as u };
|
|
1894
1915
|
|
|
1895
|
-
//# sourceMappingURL=runtime-
|
|
1916
|
+
//# sourceMappingURL=runtime-aZPUPxoB.js.map
|