@morscherlab/mint-sdk 1.2.0-beta.2 → 1.2.0-beta.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +5 -5
- package/dist/{ExperimentSelectorModal-DyPAUCLw.js → ExperimentSelectorModal-B6P2msT4.js} +3 -3
- package/dist/{ExperimentSelectorModal-DyPAUCLw.js.map → ExperimentSelectorModal-B6P2msT4.js.map} +1 -1
- package/dist/{SettingsModal-BgKY93zh.js → SettingsModal-CkNM8qAI.js} +4 -4
- package/dist/{SettingsModal-BgKY93zh.js.map → SettingsModal-CkNM8qAI.js.map} +1 -1
- package/dist/__tests__/composables/usePluginConfig.test.d.ts +15 -0
- package/dist/components/AutoGroupModal.vue.d.ts +1 -1
- package/dist/components/BioTemplateExperimentWorkspaceView.vue.d.ts +1 -1
- package/dist/components/JobsStatusTray.vue.d.ts +9 -2
- package/dist/components/SampleLegend.vue.d.ts +1 -1
- package/dist/components/SampleSelector.vue.d.ts +1 -1
- package/dist/components/SettingsModal.vue.d.ts +1 -1
- package/dist/components/SmartGroupFieldRecipe.vue.d.ts +1 -1
- package/dist/components/index.js +4 -4
- package/dist/{components-DkHddRMl.js → components-MGNL6tRn.js} +16 -10
- package/dist/components-MGNL6tRn.js.map +1 -0
- package/dist/composables/index.d.ts +3 -2
- package/dist/composables/index.js +8 -8
- package/dist/composables/useGeneratedAnalysis.d.ts +3 -1
- package/dist/composables/useJobsStatusTray.d.ts +25 -1
- package/dist/composables/usePluginClient.d.ts +2 -0
- package/dist/composables/usePluginConfig.d.ts +25 -0
- package/dist/{composables-C_i90sGS.js → composables-CKxOcvgh.js} +140 -5
- package/dist/composables-CKxOcvgh.js.map +1 -0
- package/dist/{experiment-Cq145oEW.js → experiment-Y9Iz7KYi.js} +2 -2
- package/dist/{experiment-Cq145oEW.js.map → experiment-Y9Iz7KYi.js.map} +1 -1
- package/dist/index.js +12 -12
- package/dist/install.js +4 -4
- package/dist/stores/auth.d.ts +6 -0
- package/dist/stores/index.js +2 -2
- package/dist/templates/index.js +2 -2
- package/dist/{templates-DsP51i-S.js → templates-BTJ9C9Kb.js} +2 -2
- package/dist/{templates-DsP51i-S.js.map → templates-BTJ9C9Kb.js.map} +1 -1
- package/dist/types/auth.d.ts +1 -0
- package/dist/{useApi-J6zFkHmn.js → useApi-CDBq6z23.js} +2 -1
- package/dist/useApi-CDBq6z23.js.map +1 -0
- package/dist/{useControlSchema-BDx2Olha.js → useControlSchema-CXhxTul7.js} +10 -3
- package/dist/useControlSchema-CXhxTul7.js.map +1 -0
- package/dist/{useExperimentSelector-CV4iNfMS.js → useExperimentSelector-D0pjj9WH.js} +2 -2
- package/dist/{useExperimentSelector-CV4iNfMS.js.map → useExperimentSelector-D0pjj9WH.js.map} +1 -1
- package/dist/{useFormBuilder-BLxG3BOX.js → useFormBuilder-CuOFB3aP.js} +2 -2
- package/dist/{useFormBuilder-BLxG3BOX.js.map → useFormBuilder-CuOFB3aP.js.map} +1 -1
- package/dist/{useProtocolTemplates-CS_SQl6U.js → useProtocolTemplates-BWhQIWV5.js} +113 -22
- package/dist/useProtocolTemplates-BWhQIWV5.js.map +1 -0
- package/package.json +1 -1
- package/src/__tests__/composables/useAuth.test.ts +2 -0
- package/src/__tests__/composables/usePluginConfig.test.ts +497 -0
- package/src/__tests__/docs/frontendDocsCatalog.test.ts +17 -6
- package/src/components/JobsStatusTray.vue +16 -1
- package/src/composables/index.ts +7 -0
- package/src/composables/useAuth.ts +3 -0
- package/src/composables/useGeneratedAnalysis.ts +14 -1
- package/src/composables/useJobsStatusTray.ts +184 -17
- package/src/composables/usePluginClient.ts +5 -0
- package/src/composables/usePluginConfig.ts +250 -0
- package/src/stores/auth.ts +1 -0
- package/src/types/auth.ts +1 -0
- package/dist/components-DkHddRMl.js.map +0 -1
- package/dist/composables-C_i90sGS.js.map +0 -1
- package/dist/useApi-J6zFkHmn.js.map +0 -1
- package/dist/useControlSchema-BDx2Olha.js.map +0 -1
- package/dist/useProtocolTemplates-CS_SQl6U.js.map +0 -1
|
@@ -24,6 +24,7 @@ export { useDebouncedWatch, type DebouncedWatchCallback, type DebouncedWatchClea
|
|
|
24
24
|
export { useFormBuilder, evaluateCondition } from './useFormBuilder';
|
|
25
25
|
export { createGeneratedAnalysisTransport, useGeneratedAnalysis, usePluginJobs, type GeneratedAnalysisTransport, type GeneratedAnalysisOptions, type PluginJobRequestOptions, type PluginJobWaitOptions, type UsePluginJobsOptions, type UsePluginJobsReturn, type UseGeneratedAnalysisReturn, } from './useGeneratedAnalysis';
|
|
26
26
|
export { useAutoGroup, DEFAULT_COLORS, extractSamplesFromDesignData } from './useAutoGroup';
|
|
27
|
+
export { usePluginConfig, type UsePluginConfigReturn } from './usePluginConfig';
|
|
27
28
|
export { useReagentSeries, generateDilutionSeries, DEFAULT_PRESETS, DEFAULT_UNITS, type LevelEntry, type DilutionPreset, type UseReagentSeriesReturn, } from './useReagentSeries';
|
|
28
29
|
export { useExperimentSelector, type UseExperimentSelectorOptions, type UseExperimentSelectorReturn, } from './useExperimentSelector';
|
|
29
30
|
export { useAnalysisArtifacts, ANALYSIS_FILE_ARTIFACT_SCHEMA, type UseAnalysisArtifactsOptions, type UseAnalysisArtifactsReturn, } from './useAnalysisArtifacts';
|
|
@@ -58,5 +59,5 @@ export { getBioTemplateComponentProps, getBioTemplateComponentBindings, toBioTem
|
|
|
58
59
|
export { useBioTemplateWorkspace, type BioTemplateRendererBinding, type BioTemplateWorkspaceBindings, type BioTemplateWorkspaceTarget, type UseBioTemplateWorkspaceReturn, } from './useBioTemplateWorkspace';
|
|
59
60
|
export { useBioTemplatePresetWorkspace, type BioTemplatePresetWorkspaceBindings, type UseBioTemplatePresetWorkspaceOptions, type UseBioTemplatePresetWorkspaceReturn, } from './useBioTemplatePresetWorkspace';
|
|
60
61
|
export { useBioTemplatePackWorkspace, type UseBioTemplatePackWorkspaceOptions, type UseBioTemplatePackWorkspaceReturn, } from './useBioTemplatePackWorkspace';
|
|
61
|
-
export { buildPluginEndpointUrl, createPluginClient, downloadBlob, downloadPluginEndpoint, getPluginPageSelectorItems, pluginFormDataFromPayload, resolvePluginBaseUrl, uploadPluginEndpoint, usePluginEventStream, usePluginSettings, useCurrentExperiment, type BuildPluginEndpointUrlOptions, type DownloadBlobOptions, type DownloadPluginEndpointOptions, type PluginContract, type PluginContractSettings, type PluginClientRequestOptions, type PluginEndpointContract, type PluginEndpointDefinition, type PluginHttpMethod, type PluginNavItemContract, type PluginEndpointRequestOptions, type PluginEventStreamMessage, type PluginEventStreamOptions, type PluginFormDataPayload, type PluginFormDataValue, type CreatePluginClientOptions, type UseCurrentExperimentOptions, type UseCurrentExperimentReturn, type UsePluginEventStreamReturn, type UsePluginSettingsOptions, type UsePluginSettingsReturn, } from './usePluginClient';
|
|
62
|
-
export { combinePluginJobSources, usePluginJobCenter, type CombinedPluginJobCenterSource, type PluginJobCenterSource, type JobsStatusTrayTab, type UsePluginJobCenterOptions, type UsePluginJobCenterReturn, } from './useJobsStatusTray';
|
|
62
|
+
export { buildPluginEndpointUrl, createPluginClient, downloadBlob, downloadPluginEndpoint, getPluginPageSelectorItems, pluginFormDataFromPayload, resolvePluginBaseUrl, uploadPluginEndpoint, usePluginClient, usePluginEventStream, usePluginSettings, useCurrentExperiment, type BuildPluginEndpointUrlOptions, type DownloadBlobOptions, type DownloadPluginEndpointOptions, type PluginContract, type PluginContractSettings, type PluginClientRequestOptions, type PluginEndpointContract, type PluginEndpointDefinition, type PluginHttpMethod, type PluginNavItemContract, type PluginEndpointRequestOptions, type PluginEventStreamMessage, type PluginEventStreamOptions, type PluginFormDataPayload, type PluginFormDataValue, type CreatePluginClientOptions, type UseCurrentExperimentOptions, type UseCurrentExperimentReturn, type UsePluginEventStreamReturn, type UsePluginSettingsOptions, type UsePluginSettingsReturn, } from './usePluginClient';
|
|
63
|
+
export { combinePluginJobSources, usePluginJobCenter, useJobsStatusTray, type CombinedPluginJobCenterSource, type JobsStatusTrayAdapter, type JobStreamMessage, type PluginJobCenterSource, type JobsStatusTrayTab, type UseJobsStatusTrayOptions, type UseJobsStatusTrayReturn, type UsePluginJobCenterOptions, type UsePluginJobCenterReturn, } from './useJobsStatusTray';
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { a as SORT_OPTIONS, c as formatExperimentDate, d as resolveExperimentCode, i as EXPERIMENT_STATUS_VARIANT_MAP, l as formatExperimentStatus, n as EXPERIMENT_STATUS_LABELS, o as datePresetToISO, p as useEventListener, r as EXPERIMENT_STATUS_OPTIONS, s as experimentIdFromRoute, t as DATE_PRESET_OPTIONS, u as getExperimentStatusVariant } from "../experiment-utils-CLnzPPq5.js";
|
|
2
2
|
import { r as useRequestSyncState } from "../EmptyState-p90quq8Z.js";
|
|
3
|
-
import { A as useConcentrationUnits, C as controlsToViewIds, Ct as useTimeUtils, D as getTypeDefault, Dt as useSelectionLimit, E as getFieldRegistryEntry, Et as useListSelection, F as ATOMIC_WEIGHTS, G as createGeneratedAnalysisTransport, I as useChemicalFormula, K as useGeneratedAnalysis, N as useSequenceUtils, S as controlsToTopBarSettingsConfig, St as toMinutes, T as getDefaultControlView, W as resolveCurrentPluginId, _ as controlsToFormSchema, _t as generateTimeSlots, a as defineDoseCalculatorControlProps, b as controlsToSettingsSchema, bt as rangesOverlap, c as defineWellPlateDoseComponentBindings, ct as addMinutes, d as defineControlModel, dt as findAvailableSlots, ft as findNearestTimeSlotIndex, gt as fromMinutes, h as controlValuesToComponentProps, ht as formatTimeSlot, i as useControlSchema, l as defineWellPlateDoseControlProps, lt as compareTime, m as controlValuesToComponentBindingsById, mt as formatTime, n as defineControls, o as defineDoseDesignControlModel, p as controlValuesToComponentBindings, pt as formatDuration, q as usePluginJobs, r as getControlDefaults, s as defineWellPlateControlProps, t as defineControlComponentBindings, u as useControlWorkspace, ut as durationMinutes, v as controlsToSectionFormSchema, vt as isTimeInRange, w as controlsToViewItems, x as controlsToSidebarPanels, xt as snapToSlot, y as controlsToSectionFormSchemas, yt as parseTime, z as useAnalysisArtifacts } from "../useControlSchema-
|
|
4
|
-
import { $ as
|
|
5
|
-
import { r as useApi, t as AuthenticationRequiredError } from "../useApi-
|
|
6
|
-
import { i as usePlatformContext, n as evaluateCondition, r as useForm, t as useFormBuilder } from "../useFormBuilder-
|
|
3
|
+
import { A as useConcentrationUnits, C as controlsToViewIds, Ct as useTimeUtils, D as getTypeDefault, Dt as useSelectionLimit, E as getFieldRegistryEntry, Et as useListSelection, F as ATOMIC_WEIGHTS, G as createGeneratedAnalysisTransport, I as useChemicalFormula, K as useGeneratedAnalysis, N as useSequenceUtils, S as controlsToTopBarSettingsConfig, St as toMinutes, T as getDefaultControlView, W as resolveCurrentPluginId, _ as controlsToFormSchema, _t as generateTimeSlots, a as defineDoseCalculatorControlProps, b as controlsToSettingsSchema, bt as rangesOverlap, c as defineWellPlateDoseComponentBindings, ct as addMinutes, d as defineControlModel, dt as findAvailableSlots, ft as findNearestTimeSlotIndex, gt as fromMinutes, h as controlValuesToComponentProps, ht as formatTimeSlot, i as useControlSchema, l as defineWellPlateDoseControlProps, lt as compareTime, m as controlValuesToComponentBindingsById, mt as formatTime, n as defineControls, o as defineDoseDesignControlModel, p as controlValuesToComponentBindings, pt as formatDuration, q as usePluginJobs, r as getControlDefaults, s as defineWellPlateControlProps, t as defineControlComponentBindings, u as useControlWorkspace, ut as durationMinutes, v as controlsToSectionFormSchema, vt as isTimeInRange, w as controlsToViewItems, x as controlsToSidebarPanels, xt as snapToSlot, y as controlsToSectionFormSchemas, yt as parseTime, z as useAnalysisArtifacts } from "../useControlSchema-CXhxTul7.js";
|
|
4
|
+
import { $ as useToast, A as useFileImport, B as useDoseCalculator, D as detectDelimiter, F as extractSampleNamesFromDesignData, G as useMobileSupportGate, H as useJobsStatusTray, I as extractSampleOptionsFromDesignData, J as getInjectedFrontendRevision, K as APP_EXPERIMENT_KEY, L as unwrapExperimentDesignData, M as extractSamplesFromDesignData, N as useAutoGroup, O as parseDelimitedText, Q as useTheme, R as DEFAULT_COLORS, U as usePluginJobCenter, V as combinePluginJobSources, W as DEFAULT_MOBILE_VIEWPORT_QUERY, X as getPresenceClientId, Y as useRuntimeAlignment, Z as usePresenceHeartbeat, _ as useScheduleDrag, a as useReagentSeries, b as useExpansionSet, c as useBioTemplatePresetWorkspace, d as getBioTemplateComponentProps, et as candidateMatchesSearch, f as toBioTemplateComponentPropsByComponent, g as useExperimentSave, h as useTemplateCollection, i as generateDilutionSeries, it as useSortedItems, j as validateImportFile, k as readFileAsText, l as useBioTemplatePackWorkspace, m as useBioTemplateControls, n as DEFAULT_PRESETS, nt as useTextSearch, o as useGroupAssignment, p as useBioTemplateComponents, q as useAppExperiment, r as DEFAULT_UNITS, rt as compareSortValues, s as useRackEditor, t as useProtocolTemplates, tt as normalizeSearchQuery, u as useBioTemplateWorkspace, v as useExperimentSamples, x as useSampleGroups, y as useExperimentData, z as useWellPlateEditor } from "../useProtocolTemplates-BWhQIWV5.js";
|
|
5
|
+
import { r as useApi, t as AuthenticationRequiredError } from "../useApi-CDBq6z23.js";
|
|
6
|
+
import { i as usePlatformContext, n as evaluateCondition, r as useForm, t as useFormBuilder } from "../useFormBuilder-CuOFB3aP.js";
|
|
7
7
|
import { t as ANALYSIS_FILE_ARTIFACT_SCHEMA } from "../analysisArtifactTypes-DQ0MjwHZ.js";
|
|
8
|
-
import { B as toBioTemplateComponentProps, H as toBioTemplateComponentPropsById, L as toBioTemplateComponentBindings, P as getBioTemplateComponentBindings, R as toBioTemplateComponentBindingsById, l as requireBioTemplateControlSchema, o as getBioTemplateControlSchema } from "../templates-
|
|
9
|
-
import { n as useDebouncedWatch, t as useExperimentSelector } from "../useExperimentSelector-
|
|
10
|
-
import { A as
|
|
11
|
-
export { ANALYSIS_FILE_ARTIFACT_SCHEMA, APP_EXPERIMENT_KEY, ATOMIC_WEIGHTS, AuthenticationRequiredError, DATE_PRESET_OPTIONS, DEFAULT_COLORS, DEFAULT_MOBILE_VIEWPORT_QUERY, DEFAULT_PRESETS, DEFAULT_UNITS, EXPERIMENT_STATUS_LABELS, EXPERIMENT_STATUS_OPTIONS, EXPERIMENT_STATUS_VARIANT_MAP, SORT_OPTIONS, addMinutes, buildAnalysisArtifactTargetQuery, buildPluginEndpointUrl, candidateMatchesSearch, combinePluginJobSources, compareSortValues, compareTime, controlValuesToComponentBindings, controlValuesToComponentBindingsById, controlValuesToComponentProps, controlsToFormSchema, controlsToSectionFormSchema, controlsToSectionFormSchemas, controlsToSettingsSchema, controlsToSidebarPanels, controlsToTopBarSettingsConfig, controlsToViewIds, controlsToViewItems, coordinateToWellId, createColumnConditions, createGeneratedAnalysisTransport, createPluginClient, createPluginResourceClient, createRowConditions, createWellPlateWells, datePresetToISO, defineControlComponentBindings, defineControlModel, defineControls, defineDoseCalculatorControlProps, defineDoseDesignControlModel, defineWellPlateControlProps, defineWellPlateDoseComponentBindings, defineWellPlateDoseControlProps, detectDelimiter, downloadBlob, downloadPluginEndpoint, durationMinutes, evaluateCondition, experimentIdFromRoute, extractSampleNamesFromDesignData, extractSampleOptionsFromDesignData, extractSamplesFromDesignData, findAvailableSlots, findNearestTimeSlotIndex, formatDuration, formatExperimentDate, formatExperimentStatus, formatTime, formatTimeSlot, fromMinutes, generateDilutionSeries, generateTimeSlots, getBioTemplateComponentBindings, getBioTemplateComponentProps, getBioTemplateControlSchema, getControlDefaults, getDefaultControlView, getExperimentStatusVariant, getFieldRegistryEntry, getInjectedFrontendRevision, getPluginPageSelectorItems, getPresenceClientId, getTypeDefault, isTimeInRange, normalizeSearchQuery, parseAnalysisArtifactTarget, parseDelimitedText, parseTime, pluginFormDataFromPayload, rangesOverlap, readFileAsText, requireBioTemplateControlSchema, resolveCurrentPluginId, resolveExperimentCode, resolvePluginBaseUrl, resolvePluginFrontendBase, runWellPlateValidation, snapToSlot, toBioTemplateComponentBindings, toBioTemplateComponentBindingsById, toBioTemplateComponentProps, toBioTemplateComponentPropsByComponent, toBioTemplateComponentPropsById, toMinutes, unwrapExperimentDesignData, uploadPluginEndpoint, useAnalysisArtifacts, useApi, useAppExperiment, useAsync, useAsyncBatch, useAuth, useAutoGroup, useBioTemplateComponents, useBioTemplateControls, useBioTemplatePackWorkspace, useBioTemplatePresetWorkspace, useBioTemplateWorkspace, useChemicalFormula, useCommandHistory, useConcentrationUnits, useControlSchema, useControlWorkspace, useCurrentExperiment, useDebouncedWatch, useDoseCalculator, useEventListener, useExpansionSet, useExperimentData, useExperimentSamples, useExperimentSave, useExperimentSelector, useFileImport, useForm, useFormBuilder, useGeneratedAnalysis, useGroupAssignment, useListSelection, useMobileSupportGate, useOptimisticMutation, usePasskey, usePlatformContext, usePluginEventStream, usePluginJobCenter, usePluginJobs, usePluginSettings, usePresenceHeartbeat, useProtocolTemplates, useRackEditor, useReagentSeries, useRequestSyncState, useResourceCrud, useRuntimeAlignment, useSampleGroups, useScheduleDrag, useSelectionLimit, useSequenceUtils, useSortedItems, useTemplateCollection, useTextSearch, useTheme, useTimeUtils, useToast, useWellPainting, useWellPlateAdapter, useWellPlateEditor, useWellPlateValidation, validateImportFile, wellIdToCoordinate, wellIdsInRectangle };
|
|
8
|
+
import { B as toBioTemplateComponentProps, H as toBioTemplateComponentPropsById, L as toBioTemplateComponentBindings, P as getBioTemplateComponentBindings, R as toBioTemplateComponentBindingsById, l as requireBioTemplateControlSchema, o as getBioTemplateControlSchema } from "../templates-BTJ9C9Kb.js";
|
|
9
|
+
import { n as useDebouncedWatch, t as useExperimentSelector } from "../useExperimentSelector-D0pjj9WH.js";
|
|
10
|
+
import { A as useAsync, C as createPluginResourceClient, D as buildAnalysisArtifactTargetQuery, E as useCommandHistory, M as resolvePluginFrontendBase, N as usePasskey, O as parseAnalysisArtifactTarget, P as useAuth, S as wellIdsInRectangle, T as useOptimisticMutation, _ as createWellPlateWells, a as pluginFormDataFromPayload, b as useWellPainting, c as usePluginClient, d as buildPluginEndpointUrl, f as resolvePluginBaseUrl, g as createRowConditions, h as createColumnConditions, i as getPluginPageSelectorItems, j as useAsyncBatch, k as usePluginConfig, l as usePluginEventStream, m as useWellPlateValidation, n as downloadBlob, o as uploadPluginEndpoint, p as runWellPlateValidation, r as downloadPluginEndpoint, s as useCurrentExperiment, t as createPluginClient, u as usePluginSettings, v as useWellPlateAdapter, w as useResourceCrud, x as wellIdToCoordinate, y as coordinateToWellId } from "../composables-CKxOcvgh.js";
|
|
11
|
+
export { ANALYSIS_FILE_ARTIFACT_SCHEMA, APP_EXPERIMENT_KEY, ATOMIC_WEIGHTS, AuthenticationRequiredError, DATE_PRESET_OPTIONS, DEFAULT_COLORS, DEFAULT_MOBILE_VIEWPORT_QUERY, DEFAULT_PRESETS, DEFAULT_UNITS, EXPERIMENT_STATUS_LABELS, EXPERIMENT_STATUS_OPTIONS, EXPERIMENT_STATUS_VARIANT_MAP, SORT_OPTIONS, addMinutes, buildAnalysisArtifactTargetQuery, buildPluginEndpointUrl, candidateMatchesSearch, combinePluginJobSources, compareSortValues, compareTime, controlValuesToComponentBindings, controlValuesToComponentBindingsById, controlValuesToComponentProps, controlsToFormSchema, controlsToSectionFormSchema, controlsToSectionFormSchemas, controlsToSettingsSchema, controlsToSidebarPanels, controlsToTopBarSettingsConfig, controlsToViewIds, controlsToViewItems, coordinateToWellId, createColumnConditions, createGeneratedAnalysisTransport, createPluginClient, createPluginResourceClient, createRowConditions, createWellPlateWells, datePresetToISO, defineControlComponentBindings, defineControlModel, defineControls, defineDoseCalculatorControlProps, defineDoseDesignControlModel, defineWellPlateControlProps, defineWellPlateDoseComponentBindings, defineWellPlateDoseControlProps, detectDelimiter, downloadBlob, downloadPluginEndpoint, durationMinutes, evaluateCondition, experimentIdFromRoute, extractSampleNamesFromDesignData, extractSampleOptionsFromDesignData, extractSamplesFromDesignData, findAvailableSlots, findNearestTimeSlotIndex, formatDuration, formatExperimentDate, formatExperimentStatus, formatTime, formatTimeSlot, fromMinutes, generateDilutionSeries, generateTimeSlots, getBioTemplateComponentBindings, getBioTemplateComponentProps, getBioTemplateControlSchema, getControlDefaults, getDefaultControlView, getExperimentStatusVariant, getFieldRegistryEntry, getInjectedFrontendRevision, getPluginPageSelectorItems, getPresenceClientId, getTypeDefault, isTimeInRange, normalizeSearchQuery, parseAnalysisArtifactTarget, parseDelimitedText, parseTime, pluginFormDataFromPayload, rangesOverlap, readFileAsText, requireBioTemplateControlSchema, resolveCurrentPluginId, resolveExperimentCode, resolvePluginBaseUrl, resolvePluginFrontendBase, runWellPlateValidation, snapToSlot, toBioTemplateComponentBindings, toBioTemplateComponentBindingsById, toBioTemplateComponentProps, toBioTemplateComponentPropsByComponent, toBioTemplateComponentPropsById, toMinutes, unwrapExperimentDesignData, uploadPluginEndpoint, useAnalysisArtifacts, useApi, useAppExperiment, useAsync, useAsyncBatch, useAuth, useAutoGroup, useBioTemplateComponents, useBioTemplateControls, useBioTemplatePackWorkspace, useBioTemplatePresetWorkspace, useBioTemplateWorkspace, useChemicalFormula, useCommandHistory, useConcentrationUnits, useControlSchema, useControlWorkspace, useCurrentExperiment, useDebouncedWatch, useDoseCalculator, useEventListener, useExpansionSet, useExperimentData, useExperimentSamples, useExperimentSave, useExperimentSelector, useFileImport, useForm, useFormBuilder, useGeneratedAnalysis, useGroupAssignment, useJobsStatusTray, useListSelection, useMobileSupportGate, useOptimisticMutation, usePasskey, usePlatformContext, usePluginClient, usePluginConfig, usePluginEventStream, usePluginJobCenter, usePluginJobs, usePluginSettings, usePresenceHeartbeat, useProtocolTemplates, useRackEditor, useReagentSeries, useRequestSyncState, useResourceCrud, useRuntimeAlignment, useSampleGroups, useScheduleDrag, useSelectionLimit, useSequenceUtils, useSortedItems, useTemplateCollection, useTextSearch, useTheme, useTimeUtils, useToast, useWellPainting, useWellPlateAdapter, useWellPlateEditor, useWellPlateValidation, validateImportFile, wellIdToCoordinate, wellIdsInRectangle };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ComputedRef, Ref, ShallowRef } from 'vue';
|
|
2
|
-
import { PluginJobCenterSource } from './useJobsStatusTray';
|
|
2
|
+
import { JobsStatusTrayAdapter, PluginJobCenterSource } from './useJobsStatusTray';
|
|
3
3
|
import { GeneratedAnalysisJob, GeneratedAnalysisResult, GeneratedSession, GeneratedAnalysisManifest, PluginJobPathInput, PluginJobPathUpload, PluginJobStagedPartInput, PluginJobStagedPartUploadResult, PluginJobStaging, PluginJobStagingPagination } from '../types/generated-ui';
|
|
4
4
|
export type GeneratedAnalysisTransport = (input: RequestInfo | URL, init?: RequestInit) => Promise<Response>;
|
|
5
5
|
export interface GeneratedAnalysisTransportOptions {
|
|
@@ -53,6 +53,8 @@ export interface UsePluginJobsReturn extends PluginJobCenterSource {
|
|
|
53
53
|
pause: () => void;
|
|
54
54
|
resume: () => void;
|
|
55
55
|
dispose: () => void;
|
|
56
|
+
/** @deprecated Pass the runtime itself to SDK job UI as its source. */
|
|
57
|
+
jobsAdapter: JobsStatusTrayAdapter;
|
|
56
58
|
}
|
|
57
59
|
export type UseGeneratedAnalysisReturn = UsePluginJobsReturn;
|
|
58
60
|
export declare function createGeneratedAnalysisTransport(options?: GeneratedAnalysisTransportOptions): GeneratedAnalysisTransport;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { ComputedRef, MaybeRefOrGetter, Ref, ShallowRef } from 'vue';
|
|
2
|
-
import { JobListPayload, JobState, JobStateInput } from '../types/jobs';
|
|
2
|
+
import { JobListPayload, JobState, JobStateInput, JobStreamData } from '../types/jobs';
|
|
3
|
+
import { UsePluginEventStreamReturn } from './usePluginClient';
|
|
3
4
|
export type JobsStatusTrayTab = 'active' | 'history';
|
|
4
5
|
/**
|
|
5
6
|
* The canonical owner of a collection of plugin jobs.
|
|
@@ -26,10 +27,29 @@ export interface CombinedPluginJobCenterSource extends PluginJobCenterSource {
|
|
|
26
27
|
* dispatching a mutation to the wrong owner.
|
|
27
28
|
*/
|
|
28
29
|
export declare function combinePluginJobSources(sources: readonly PluginJobCenterSource[]): CombinedPluginJobCenterSource;
|
|
30
|
+
/** @deprecated Prefer a {@link PluginJobCenterSource}. */
|
|
31
|
+
export interface JobsStatusTrayAdapter {
|
|
32
|
+
listJobs?: () => Promise<JobListPayload | readonly JobStateInput[]>;
|
|
33
|
+
cancelJob?: (job: JobState) => Promise<JobStateInput | void>;
|
|
34
|
+
deleteJob?: (job: JobState) => Promise<boolean | void>;
|
|
35
|
+
clearFinishedJobs?: (jobs: readonly JobState[]) => Promise<number | void>;
|
|
36
|
+
}
|
|
29
37
|
export interface UsePluginJobCenterOptions {
|
|
30
38
|
source?: MaybeRefOrGetter<PluginJobCenterSource | undefined>;
|
|
39
|
+
/** @deprecated Pass a source with its canonical jobs ref. */
|
|
40
|
+
jobs?: MaybeRefOrGetter<readonly JobStateInput[] | undefined>;
|
|
41
|
+
/** @deprecated Pass source actions instead. */
|
|
42
|
+
adapter?: MaybeRefOrGetter<JobsStatusTrayAdapter | undefined>;
|
|
43
|
+
/** @deprecated Event handling belongs to the source runtime. */
|
|
44
|
+
eventStream?: MaybeRefOrGetter<UsePluginEventStreamReturn<JobStreamData> | undefined>;
|
|
31
45
|
loadOnMount?: boolean;
|
|
32
46
|
}
|
|
47
|
+
export interface UseJobsStatusTrayOptions extends UsePluginJobCenterOptions {
|
|
48
|
+
}
|
|
49
|
+
export interface JobStreamMessage {
|
|
50
|
+
event: string;
|
|
51
|
+
data: JobStreamData;
|
|
52
|
+
}
|
|
33
53
|
export interface UsePluginJobCenterReturn {
|
|
34
54
|
jobs: ComputedRef<JobState[]>;
|
|
35
55
|
activeJobs: ComputedRef<JobState[]>;
|
|
@@ -49,11 +69,13 @@ export interface UsePluginJobCenterReturn {
|
|
|
49
69
|
close: () => void;
|
|
50
70
|
toggle: () => void;
|
|
51
71
|
refresh: () => Promise<boolean>;
|
|
72
|
+
applyStreamMessage: (message: JobStreamMessage) => void;
|
|
52
73
|
cancelJob: (job: JobState) => Promise<boolean>;
|
|
53
74
|
deleteJob: (job: JobState) => Promise<boolean>;
|
|
54
75
|
clearFinished: () => Promise<boolean>;
|
|
55
76
|
isPending: (job: JobState) => boolean;
|
|
56
77
|
}
|
|
78
|
+
export type UseJobsStatusTrayReturn = UsePluginJobCenterReturn;
|
|
57
79
|
/**
|
|
58
80
|
* Headless controller for plugin job presentation and actions.
|
|
59
81
|
*
|
|
@@ -61,3 +83,5 @@ export interface UsePluginJobCenterReturn {
|
|
|
61
83
|
* source. The controller never mirrors source jobs into another ref.
|
|
62
84
|
*/
|
|
63
85
|
export declare function usePluginJobCenter(options?: UsePluginJobCenterOptions): UsePluginJobCenterReturn;
|
|
86
|
+
/** @deprecated Use `usePluginJobCenter()` for the plugin job-center controller. */
|
|
87
|
+
export declare function useJobsStatusTray(options?: UseJobsStatusTrayOptions): UseJobsStatusTrayReturn;
|
|
@@ -209,6 +209,8 @@ export declare function createPluginClient<TClient extends object = GeneratedPlu
|
|
|
209
209
|
export declare function uploadPluginEndpoint<TResponse = unknown>(contract: PluginContract, endpoint: PluginEndpointDefinition, payload?: unknown, options?: PluginEndpointRequestOptions): Promise<TResponse>;
|
|
210
210
|
/** Fetch a generated plugin endpoint as a Blob and optionally trigger a browser download. */
|
|
211
211
|
export declare function downloadPluginEndpoint(contract: PluginContract, endpoint: PluginEndpointDefinition, payload?: unknown, options?: DownloadPluginEndpointOptions): Promise<Blob>;
|
|
212
|
+
/** @deprecated Use `useGeneratedPluginClient()` for generated clients. */
|
|
213
|
+
export declare function usePluginClient<TClient>(client: TClient): TClient;
|
|
212
214
|
/** Load, edit, and persist plugin settings from platform config or the plugin-local settings router. */
|
|
213
215
|
export declare function usePluginSettings<TSettings = Record<string, unknown>>(options?: UsePluginSettingsOptions | string): UsePluginSettingsReturn<TSettings>;
|
|
214
216
|
/** Consume a generated plugin SSE endpoint with auth headers, reconnect, and teardown. */
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { Ref, ComputedRef } from 'vue';
|
|
2
|
+
export interface UsePluginConfigReturn {
|
|
3
|
+
/** Editable plugin configuration values. */
|
|
4
|
+
config: Ref<Record<string, unknown>>;
|
|
5
|
+
/** Whether the config is currently loading. */
|
|
6
|
+
isLoading: Ref<boolean>;
|
|
7
|
+
/** Whether the config is currently saving. */
|
|
8
|
+
isSaving: Ref<boolean>;
|
|
9
|
+
/** Error message from the last failed operation, or null. */
|
|
10
|
+
error: Ref<string | null>;
|
|
11
|
+
/** Timestamp of the last successful load, or null. */
|
|
12
|
+
lastLoadedAt: Ref<Date | null>;
|
|
13
|
+
/** Timestamp of the last successful save, or null. */
|
|
14
|
+
lastSavedAt: Ref<Date | null>;
|
|
15
|
+
/** Whether local config differs from the last loaded or saved snapshot. */
|
|
16
|
+
isDirty: ComputedRef<boolean>;
|
|
17
|
+
/** Load plugin configuration from the platform. */
|
|
18
|
+
load: () => Promise<void>;
|
|
19
|
+
/** Save plugin configuration to the platform. */
|
|
20
|
+
save: () => Promise<boolean>;
|
|
21
|
+
/** Restore the last loaded or saved configuration snapshot. */
|
|
22
|
+
reset: () => void;
|
|
23
|
+
}
|
|
24
|
+
/** @deprecated Use `usePluginSettings()` for typed plugin settings. */
|
|
25
|
+
export declare function usePluginConfig(pluginName?: string): UsePluginConfigReturn;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { r as useRequestSyncState } from "./EmptyState-p90quq8Z.js";
|
|
2
|
-
import { B as currentExperimentFromContext, U as resolveCurrentExperimentId, V as getInjectedPlatformContext, et as useEventStream } from "./useControlSchema-
|
|
3
|
-
import { i as useAuthStore, n as authenticationRequiredError, o as useSettingsStore, r as useApi, t as AuthenticationRequiredError } from "./useApi-
|
|
4
|
-
import { i as usePlatformContext } from "./useFormBuilder-
|
|
2
|
+
import { B as currentExperimentFromContext, U as resolveCurrentExperimentId, V as getInjectedPlatformContext, et as useEventStream } from "./useControlSchema-CXhxTul7.js";
|
|
3
|
+
import { i as useAuthStore, n as authenticationRequiredError, o as useSettingsStore, r as useApi, t as AuthenticationRequiredError } from "./useApi-CDBq6z23.js";
|
|
4
|
+
import { i as usePlatformContext } from "./useFormBuilder-CuOFB3aP.js";
|
|
5
5
|
import { computed, getCurrentInstance, onMounted, onUnmounted, ref, shallowRef, toValue, watch } from "vue";
|
|
6
6
|
import axios from "axios";
|
|
7
7
|
//#region src/composables/useAuth.ts
|
|
@@ -26,6 +26,7 @@ function useAuth() {
|
|
|
26
26
|
passkeyEnabled: response.data.passkey_enabled,
|
|
27
27
|
passkeyRegistered: response.data.passkey_registered ?? false,
|
|
28
28
|
registrationEnabled: response.data.registration_enabled ?? false,
|
|
29
|
+
databaseMode: response.data.database_mode ?? "none",
|
|
29
30
|
experimentVisibilityMode: response.data.access?.experiment_visibility_mode ?? response.data.access?.experimentVisibilityMode ?? "open"
|
|
30
31
|
};
|
|
31
32
|
authStore.setAuthConfig(config);
|
|
@@ -37,6 +38,7 @@ function useAuth() {
|
|
|
37
38
|
passkeyEnabled: false,
|
|
38
39
|
passkeyRegistered: false,
|
|
39
40
|
registrationEnabled: false,
|
|
41
|
+
databaseMode: "none",
|
|
40
42
|
experimentVisibilityMode: "open"
|
|
41
43
|
};
|
|
42
44
|
}
|
|
@@ -611,6 +613,135 @@ function useAsyncBatch(asyncFns) {
|
|
|
611
613
|
};
|
|
612
614
|
}
|
|
613
615
|
//#endregion
|
|
616
|
+
//#region src/composables/usePluginConfig.ts
|
|
617
|
+
var PLATFORM_OWNED_SETTINGS_KEY$1 = "allowed_experiment_types";
|
|
618
|
+
function cloneConfig(config) {
|
|
619
|
+
return JSON.parse(JSON.stringify(config));
|
|
620
|
+
}
|
|
621
|
+
function hasOwnConfig(config, key) {
|
|
622
|
+
return Object.prototype.hasOwnProperty.call(config, key);
|
|
623
|
+
}
|
|
624
|
+
function changedTopLevelKeys(current, saved) {
|
|
625
|
+
return new Set([...new Set([...Object.keys(current), ...Object.keys(saved)])].filter((key) => JSON.stringify(current[key]) !== JSON.stringify(saved[key])));
|
|
626
|
+
}
|
|
627
|
+
function topLevelConfigPatch(current, keys) {
|
|
628
|
+
return Object.fromEntries([...keys].map((key) => [key, hasOwnConfig(current, key) ? current[key] : null]));
|
|
629
|
+
}
|
|
630
|
+
function platformOwnedConfigPatch(config) {
|
|
631
|
+
return { [PLATFORM_OWNED_SETTINGS_KEY$1]: hasOwnConfig(config, PLATFORM_OWNED_SETTINGS_KEY$1) ? config[PLATFORM_OWNED_SETTINGS_KEY$1] : null };
|
|
632
|
+
}
|
|
633
|
+
function responseConfigPayload(response) {
|
|
634
|
+
return response.config ?? response.settings ?? {};
|
|
635
|
+
}
|
|
636
|
+
/** @deprecated Use `usePluginSettings()` for typed plugin settings. */
|
|
637
|
+
function usePluginConfig(pluginName) {
|
|
638
|
+
const injectedContext = getInjectedPlatformContext();
|
|
639
|
+
const { plugin } = usePlatformContext();
|
|
640
|
+
const platformApi = useApi();
|
|
641
|
+
const pluginApi = useApi({ baseUrl: injectedContext?.plugin?.api_prefix ?? plugin.value?.api_prefix });
|
|
642
|
+
const resolvedName = computed(() => pluginName ?? plugin.value?.name ?? injectedContext?.plugin?.name ?? "");
|
|
643
|
+
const usesPluginSettingsApi = computed(() => {
|
|
644
|
+
const currentPlugin = injectedContext?.plugin ?? plugin.value;
|
|
645
|
+
return currentPlugin?.settings_api === "plugin" && resolvedName.value === currentPlugin.name;
|
|
646
|
+
});
|
|
647
|
+
const config = ref({});
|
|
648
|
+
const savedConfig = ref({});
|
|
649
|
+
const revision = ref(null);
|
|
650
|
+
const request = useRequestSyncState("Plugin config request failed.");
|
|
651
|
+
const isLoading = ref(false);
|
|
652
|
+
const isSaving = ref(false);
|
|
653
|
+
const error = request.error;
|
|
654
|
+
const lastLoadedAt = request.lastLoadedAt;
|
|
655
|
+
const lastSavedAt = request.lastSavedAt;
|
|
656
|
+
const isDirty = computed(() => {
|
|
657
|
+
return JSON.stringify(config.value) !== JSON.stringify(savedConfig.value);
|
|
658
|
+
});
|
|
659
|
+
async function load() {
|
|
660
|
+
const name = resolvedName.value;
|
|
661
|
+
if (!name) return;
|
|
662
|
+
isLoading.value = true;
|
|
663
|
+
try {
|
|
664
|
+
const response = usesPluginSettingsApi.value ? await request.run(() => pluginApi.get("/settings"), {
|
|
665
|
+
success: "load",
|
|
666
|
+
errorMessage: "Failed to load plugin config"
|
|
667
|
+
}) : await request.run(() => platformApi.get(`/plugins/${encodeURIComponent(name)}/config`), {
|
|
668
|
+
success: "load",
|
|
669
|
+
errorMessage: "Failed to load plugin config"
|
|
670
|
+
});
|
|
671
|
+
const responseConfig = responseConfigPayload(response);
|
|
672
|
+
config.value = cloneConfig(responseConfig);
|
|
673
|
+
savedConfig.value = cloneConfig(responseConfig);
|
|
674
|
+
revision.value = response.revision ?? null;
|
|
675
|
+
} catch {} finally {
|
|
676
|
+
isLoading.value = false;
|
|
677
|
+
}
|
|
678
|
+
}
|
|
679
|
+
async function save() {
|
|
680
|
+
const name = resolvedName.value;
|
|
681
|
+
if (!name) return false;
|
|
682
|
+
isSaving.value = true;
|
|
683
|
+
try {
|
|
684
|
+
const payload = cloneConfig(config.value);
|
|
685
|
+
let response;
|
|
686
|
+
let nextRevision = revision.value;
|
|
687
|
+
if (usesPluginSettingsApi.value) {
|
|
688
|
+
response = await request.run(() => pluginApi.put("/settings", payload, revision.value ? { headers: { "If-Match": `"${revision.value}"` } } : void 0), {
|
|
689
|
+
success: "save",
|
|
690
|
+
errorMessage: "Failed to save plugin config"
|
|
691
|
+
});
|
|
692
|
+
nextRevision = response.revision ?? nextRevision;
|
|
693
|
+
} else {
|
|
694
|
+
const dirtyKeys = changedTopLevelKeys(payload, savedConfig.value);
|
|
695
|
+
const platformOwnedChanged = dirtyKeys.has(PLATFORM_OWNED_SETTINGS_KEY$1);
|
|
696
|
+
const typedKeys = [...dirtyKeys].filter((key) => key !== PLATFORM_OWNED_SETTINGS_KEY$1);
|
|
697
|
+
if (typedKeys.length) {
|
|
698
|
+
response = await request.run(() => platformApi.patch(`/plugins/${encodeURIComponent(name)}/config`, { config: topLevelConfigPatch(payload, typedKeys) }), {
|
|
699
|
+
success: "save",
|
|
700
|
+
errorMessage: "Failed to save plugin config"
|
|
701
|
+
});
|
|
702
|
+
nextRevision = response.revision ?? nextRevision;
|
|
703
|
+
}
|
|
704
|
+
if (platformOwnedChanged) {
|
|
705
|
+
response = await request.run(() => platformApi.patch(`/plugins/${encodeURIComponent(name)}/config`, { config: platformOwnedConfigPatch(payload) }), {
|
|
706
|
+
success: "save",
|
|
707
|
+
errorMessage: "Failed to save plugin config"
|
|
708
|
+
});
|
|
709
|
+
nextRevision = response.revision ?? nextRevision;
|
|
710
|
+
}
|
|
711
|
+
}
|
|
712
|
+
if (!response) return true;
|
|
713
|
+
const responseConfig = responseConfigPayload(response);
|
|
714
|
+
config.value = cloneConfig(responseConfig);
|
|
715
|
+
savedConfig.value = cloneConfig(responseConfig);
|
|
716
|
+
revision.value = response.revision ?? nextRevision;
|
|
717
|
+
return true;
|
|
718
|
+
} catch {
|
|
719
|
+
return false;
|
|
720
|
+
} finally {
|
|
721
|
+
isSaving.value = false;
|
|
722
|
+
}
|
|
723
|
+
}
|
|
724
|
+
function reset() {
|
|
725
|
+
config.value = cloneConfig(savedConfig.value);
|
|
726
|
+
request.clearError();
|
|
727
|
+
}
|
|
728
|
+
onMounted(() => {
|
|
729
|
+
load();
|
|
730
|
+
});
|
|
731
|
+
return {
|
|
732
|
+
config,
|
|
733
|
+
isLoading,
|
|
734
|
+
isSaving,
|
|
735
|
+
error,
|
|
736
|
+
lastLoadedAt,
|
|
737
|
+
lastSavedAt,
|
|
738
|
+
isDirty,
|
|
739
|
+
load,
|
|
740
|
+
save,
|
|
741
|
+
reset
|
|
742
|
+
};
|
|
743
|
+
}
|
|
744
|
+
//#endregion
|
|
614
745
|
//#region src/composables/analysisArtifactTarget.ts
|
|
615
746
|
var EXPERIMENT_ID = "experiment_id";
|
|
616
747
|
var ARTIFACT_PLUGIN_ID = "artifact_plugin_id";
|
|
@@ -1499,6 +1630,10 @@ async function downloadPluginEndpoint(contract, endpoint, payload, options = {})
|
|
|
1499
1630
|
function normalizePluginSettingsOptions(options = {}) {
|
|
1500
1631
|
return typeof options === "string" ? { pluginName: options } : options;
|
|
1501
1632
|
}
|
|
1633
|
+
/** @deprecated Use `useGeneratedPluginClient()` for generated clients. */
|
|
1634
|
+
function usePluginClient(client) {
|
|
1635
|
+
return client;
|
|
1636
|
+
}
|
|
1502
1637
|
var PLATFORM_OWNED_SETTINGS_KEY = "allowed_experiment_types";
|
|
1503
1638
|
function cloneRecord(value) {
|
|
1504
1639
|
return JSON.parse(JSON.stringify(value));
|
|
@@ -1763,6 +1898,6 @@ function useCurrentExperiment(options = {}) {
|
|
|
1763
1898
|
};
|
|
1764
1899
|
}
|
|
1765
1900
|
//#endregion
|
|
1766
|
-
export {
|
|
1901
|
+
export { useAsync as A, createPluginResourceClient as C, buildAnalysisArtifactTargetQuery as D, useCommandHistory as E, resolvePluginFrontendBase as M, usePasskey as N, parseAnalysisArtifactTarget as O, useAuth as P, wellIdsInRectangle as S, useOptimisticMutation as T, createWellPlateWells as _, pluginFormDataFromPayload as a, useWellPainting as b, usePluginClient as c, buildPluginEndpointUrl as d, resolvePluginBaseUrl as f, createRowConditions as g, createColumnConditions as h, getPluginPageSelectorItems as i, useAsyncBatch as j, usePluginConfig as k, usePluginEventStream as l, useWellPlateValidation as m, downloadBlob as n, uploadPluginEndpoint as o, runWellPlateValidation as p, downloadPluginEndpoint as r, useCurrentExperiment as s, createPluginClient as t, usePluginSettings as u, useWellPlateAdapter as v, useResourceCrud as w, wellIdToCoordinate as x, coordinateToWellId as y };
|
|
1767
1902
|
|
|
1768
|
-
//# sourceMappingURL=composables-
|
|
1903
|
+
//# sourceMappingURL=composables-CKxOcvgh.js.map
|