@morscherlab/mint-sdk 1.2.0-beta.8 → 1.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +60 -0
- package/dist/{ExperimentPopover-CfOdh5Rm.js → ExperimentPopover-CJdNlCZb.js} +24 -15
- package/dist/ExperimentPopover-CJdNlCZb.js.map +1 -0
- package/dist/{ExperimentSelectorModal-DvIagrxY.js → ExperimentSelectorModal-DCXmwKNS.js} +5 -5
- package/dist/ExperimentSelectorModal-DCXmwKNS.js.map +1 -0
- package/dist/{SettingsModal-W3TYfnP9.js → SettingsModal-BYR20I4c.js} +5 -5
- package/dist/SettingsModal-BYR20I4c.js.map +1 -0
- package/dist/{EmptyState-NBqf2_8z.js → Skeleton-BAF3CKY7.js} +111 -93
- package/dist/Skeleton-BAF3CKY7.js.map +1 -0
- package/dist/__tests__/components/DataStates.test.d.ts +1 -0
- package/dist/__tests__/components/ExperimentTimeline.test.d.ts +1 -0
- package/dist/__tests__/components/FileBrowserModal.test.d.ts +1 -0
- package/dist/__tests__/components/FilePicker.state.test.d.ts +1 -0
- package/dist/__tests__/components/FilePicker.test.d.ts +1 -0
- package/dist/__tests__/components/PlotlyChart.test.d.ts +1 -0
- package/dist/__tests__/components/iconButtonIconSizing.test.d.ts +1 -0
- package/dist/__tests__/composables/useFileBrowser.test.d.ts +1 -0
- package/dist/__tests__/composables/useListReorder.test.d.ts +1 -0
- package/dist/__tests__/composables/usePlatformFilePickerAdapter.test.d.ts +1 -0
- package/dist/__tests__/styles/cssTokens.test.d.ts +1 -0
- package/dist/apiErrors.d.ts +26 -0
- package/dist/components/ActionMenu.vue.d.ts +1 -1
- package/dist/components/AppPluginSwitcher.vue.d.ts +2 -0
- package/dist/components/AuditTrail.vue.d.ts +13 -0
- package/dist/components/BaseInput.vue.d.ts +1 -1
- package/dist/components/BaseSelect.vue.d.ts +1 -1
- package/dist/components/BaseTextarea.vue.d.ts +1 -1
- package/dist/components/BatchProgressList.vue.d.ts +17 -0
- package/dist/components/BioTemplateExperimentWorkspaceView.vue.d.ts +2 -2
- package/dist/components/BioTemplatePackWorkspaceView.vue.d.ts +2 -2
- package/dist/components/ConcentrationInput.vue.d.ts +1 -1
- package/dist/components/DataFrame.vue.d.ts +14 -2
- package/dist/components/DatePicker.vue.d.ts +2 -2
- package/dist/components/DateTimePicker.vue.d.ts +3 -1
- package/dist/components/ExperimentDataViewer.vue.d.ts +26 -1
- package/dist/components/ExperimentPopover.vue.d.ts +1 -0
- package/dist/components/ExperimentTimeline.vue.d.ts +29 -1
- package/dist/components/FileBrowserModal.vue.d.ts +99 -0
- package/dist/components/FilePicker.vue.d.ts +32 -0
- package/dist/components/FileUploader.vue.d.ts +5 -2
- package/dist/components/FormulaInput.vue.d.ts +1 -1
- package/dist/components/GeneratedPlotlyResult.vue.d.ts +1 -3
- package/dist/components/LcmsSequenceTable.vue.d.ts +29 -1
- package/dist/components/MobileSupportGate.vue.d.ts +1 -1
- package/dist/components/MoleculeInput.vue.d.ts +1 -1
- package/dist/components/NumberInput.vue.d.ts +1 -1
- package/dist/components/PlotlyChart.vue.d.ts +59 -0
- package/dist/components/ProgressBar.vue.d.ts +1 -1
- package/dist/components/ProtocolStepEditor.vue.d.ts +1 -0
- package/dist/components/ReagentList.vue.d.ts +29 -1
- package/dist/components/ResourceCard.vue.d.ts +1 -1
- package/dist/components/SampleHierarchyTree.vue.d.ts +29 -1
- package/dist/components/SampleSelector.drag.d.ts +13 -0
- package/dist/components/SampleSelector.tree.d.ts +2 -0
- package/dist/components/SampleSelector.vue.d.ts +34 -1
- package/dist/components/ScheduleCalendar.vue.d.ts +20 -0
- package/dist/components/SecretInput.vue.d.ts +1 -1
- package/dist/components/SequenceInput.vue.d.ts +1 -1
- package/dist/components/SmartGroupFieldRecipe.vue.d.ts +1 -0
- package/dist/components/StatusIndicator.vue.d.ts +1 -1
- package/dist/components/TagsInput.vue.d.ts +1 -1
- package/dist/components/TimePicker.vue.d.ts +2 -1
- package/dist/components/TimeRangeInput.vue.d.ts +1 -1
- package/dist/components/UnitInput.vue.d.ts +1 -1
- package/dist/components/WellPlate.geometry.d.ts +15 -0
- package/dist/components/WellPlate.interaction.d.ts +13 -0
- package/dist/components/WellPlate.vue.d.ts +30 -1
- package/dist/components/fileBrowserPresentation.d.ts +10 -0
- package/dist/components/index.d.ts +4 -0
- package/dist/components/index.js +8 -8
- package/dist/components/internal/AppTopBarPageSelectorInternal.vue.d.ts +2 -0
- package/dist/components/internal/DataStateInternal.vue.d.ts +43 -0
- package/dist/components/internal/FileBrowserDialogInternal.vue.d.ts +34 -0
- package/dist/components/internal/FileBrowserListingInternal.vue.d.ts +25 -0
- package/dist/components/internal/FileBrowserToolbarInternal.vue.d.ts +26 -0
- package/dist/components/internal/FilePickerPreviewInternal.vue.d.ts +18 -0
- package/dist/components/internal/FilePickerTreeInternal.vue.d.ts +31 -0
- package/dist/{components-B80gV0P6.js → components-DIum5hkx.js} +5415 -2753
- package/dist/components-DIum5hkx.js.map +1 -0
- package/dist/composables/controlSchemaTypes.d.ts +34 -0
- package/dist/composables/filePicker/localFiles.d.ts +3 -0
- package/dist/composables/filePicker/usePickerNavigation.d.ts +96 -0
- package/dist/composables/filePicker/usePickerSelection.d.ts +31 -0
- package/dist/composables/filePicker/validation.d.ts +5 -0
- package/dist/composables/index.d.ts +3 -0
- package/dist/composables/index.js +10 -10
- package/dist/composables/useApi.d.ts +14 -7
- package/dist/composables/useDropdownState.d.ts +18 -2
- package/dist/composables/useEventStream.d.ts +9 -0
- package/dist/composables/useFileBrowser.d.ts +55 -0
- package/dist/composables/useFilePicker.d.ts +189 -0
- package/dist/composables/useListReorder.d.ts +90 -0
- package/dist/composables/useMenuKeyboard.d.ts +2 -2
- package/dist/composables/usePlatformFilePickerAdapter.d.ts +11 -0
- package/dist/composables/usePluginConfig.d.ts +3 -1
- package/dist/composables/useRequestSyncState.d.ts +42 -2
- package/dist/composables/useScheduleDrag.d.ts +1 -0
- package/dist/{composables-C8mmD5ta.js → composables-mFXsTA4g.js} +307 -74
- package/dist/composables-mFXsTA4g.js.map +1 -0
- package/dist/{useApi-CDBq6z23.js → errors-BLuqMee5.js} +178 -16
- package/dist/errors-BLuqMee5.js.map +1 -0
- package/dist/{experiment-Y9Iz7KYi.js → experiment-CVDRAnqp.js} +3 -8
- package/dist/experiment-CVDRAnqp.js.map +1 -0
- package/dist/{experiment-utils-DV3DrvE_.js → experiment-utils-CV2Wza3z.js} +1 -1
- package/dist/experiment-utils-CV2Wza3z.js.map +1 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +15 -15
- package/dist/install.js +2 -7
- package/dist/install.js.map +1 -1
- package/dist/permissions.d.ts +42 -1
- package/dist/permissions.js +20 -10
- package/dist/permissions.js.map +1 -1
- package/dist/stores/index.d.ts +1 -1
- package/dist/stores/index.js +3 -3
- package/dist/stores/settings.d.ts +31 -1
- package/dist/styles.css +15162 -32475
- package/dist/templates/index.js +2 -4
- package/dist/{templates-CK72aKO1.js → templates-CmGfmBRA.js} +291 -85
- package/dist/templates-CmGfmBRA.js.map +1 -0
- package/dist/types/fileBrowserTypes.d.ts +77 -0
- package/dist/types/filePicker.d.ts +77 -0
- package/dist/types/index.d.ts +2 -0
- package/dist/{useControlSchema-_OVhavKq.js → useControlSchema-DldpxNOP.js} +234 -1121
- package/dist/useControlSchema-DldpxNOP.js.map +1 -0
- package/dist/{useDropdownState-D5G4UvWd.js → useDropdownState-C7hRiVQf.js} +22 -6
- package/dist/useDropdownState-C7hRiVQf.js.map +1 -0
- package/dist/{useExperimentSelector-DSEckf_g.js → useExperimentSelector-CEcIaueJ.js} +4 -4
- package/dist/{useExperimentSelector-DSEckf_g.js.map → useExperimentSelector-CEcIaueJ.js.map} +1 -1
- package/dist/{useFormBuilder-Bd714C7y.js → useFormBuilder-z5L_dUIy.js} +2 -2
- package/dist/{useFormBuilder-Bd714C7y.js.map → useFormBuilder-z5L_dUIy.js.map} +1 -1
- package/dist/utils/color.d.ts +13 -0
- package/dist/utils/errors.d.ts +9 -0
- package/dist/{useProtocolTemplates-Dq5Pzwyd.js → validation-uwoJGEb6.js} +231 -158
- package/dist/validation-uwoJGEb6.js.map +1 -0
- package/package.json +1 -1
- package/src/__tests__/apiErrors.test.ts +81 -0
- package/src/__tests__/components/ActionMenu.test.ts +94 -0
- package/src/__tests__/components/DataFrame.test.ts +183 -11
- package/src/__tests__/components/DataStates.test.ts +176 -0
- package/src/__tests__/components/DatePicker.test.ts +76 -0
- package/src/__tests__/components/DateTimePicker.test.ts +36 -0
- package/src/__tests__/components/ExperimentPopover.test.ts +30 -0
- package/src/__tests__/components/ExperimentTimeline.test.ts +63 -0
- package/src/__tests__/components/FileBrowserModal.test.ts +460 -0
- package/src/__tests__/components/FilePicker.state.test.ts +287 -0
- package/src/__tests__/components/FilePicker.test.ts +487 -0
- package/src/__tests__/components/GeneratedPlotlyResult.test.ts +52 -5
- package/src/__tests__/components/GroupAssigner.test.ts +53 -0
- package/src/__tests__/components/LcmsSequenceTable.test.ts +22 -0
- package/src/__tests__/components/PlotlyChart.test.ts +305 -0
- package/src/__tests__/components/RackEditor.test.ts +35 -0
- package/src/__tests__/components/ReagentList.test.ts +64 -2
- package/src/__tests__/components/RetiredStyles.test.ts +31 -0
- package/src/__tests__/components/SampleSelector.drag.test.ts +51 -1
- package/src/__tests__/components/ScheduleCalendar.test.ts +63 -0
- package/src/__tests__/components/SegmentedControl.test.ts +107 -0
- package/src/__tests__/components/TimePicker.test.ts +61 -0
- package/src/__tests__/components/WellPlate.interaction.test.ts +59 -0
- package/src/__tests__/components/iconButtonIconSizing.test.ts +18 -0
- package/src/__tests__/composables/useApi.test.ts +92 -9
- package/src/__tests__/composables/useDropdownState.test.ts +58 -1
- package/src/__tests__/composables/useFileBrowser.test.ts +305 -0
- package/src/__tests__/composables/useGeneratedAnalysis.test.ts +7 -2
- package/src/__tests__/composables/useListReorder.test.ts +145 -0
- package/src/__tests__/composables/usePlatformFilePickerAdapter.test.ts +67 -0
- package/src/__tests__/composables/usePluginClient.test.ts +3 -0
- package/src/__tests__/composables/useRequestSyncState.test.ts +140 -0
- package/src/__tests__/stores/settings.test.ts +71 -1
- package/src/__tests__/styles/cssTokens.test.ts +131 -0
- package/src/__tests__/utils/permissions.test.ts +68 -0
- package/src/apiErrors.ts +85 -0
- package/src/components/ActionMenu.vue +45 -88
- package/src/components/AlertBox.vue +0 -4
- package/src/components/AppAvatarMenu.vue +2 -14
- package/src/components/AppLayout.vue +0 -4
- package/src/components/AppPluginSwitcher.story.vue +87 -0
- package/src/components/AppPluginSwitcher.vue +2 -5
- package/src/components/AppSidebar.vue +0 -4
- package/src/components/AppToastContainer.vue +6 -8
- package/src/components/AppTopBar.vue +0 -4
- package/src/components/ArtifactSaveDialog.vue +0 -4
- package/src/components/ArtifactSelectorModal.vue +0 -4
- package/src/components/AuditTrail.story.vue +18 -0
- package/src/components/AuditTrail.vue +27 -7
- package/src/components/AutoGroupModal.vue +0 -4
- package/src/components/Avatar.vue +0 -4
- package/src/components/BaseButton.vue +0 -4
- package/src/components/BaseCheckbox.vue +0 -4
- package/src/components/BaseInput.vue +0 -4
- package/src/components/BaseModal.vue +0 -4
- package/src/components/BasePill.vue +0 -4
- package/src/components/BaseRadioGroup.vue +0 -4
- package/src/components/BaseSelect.vue +0 -4
- package/src/components/BaseSlider.vue +0 -4
- package/src/components/BaseTabs.vue +0 -4
- package/src/components/BaseTextarea.vue +0 -4
- package/src/components/BaseToggle.vue +0 -4
- package/src/components/BatchProgressList.story.vue +18 -0
- package/src/components/BatchProgressList.vue +32 -4
- package/src/components/Breadcrumb.vue +0 -4
- package/src/components/Calendar.vue +0 -4
- package/src/components/ChartContainer.story.vue +1 -1
- package/src/components/ChartContainer.vue +0 -4
- package/src/components/ChemicalFormula.vue +0 -4
- package/src/components/CollapsibleCard.vue +0 -4
- package/src/components/ColorSlider.vue +0 -4
- package/src/components/ConcentrationInput.vue +0 -4
- package/src/components/ConfirmDialog.vue +0 -4
- package/src/components/DataFrame.story.vue +14 -0
- package/src/components/DataFrame.vue +97 -23
- package/src/components/DatePicker.vue +73 -27
- package/src/components/DateTimePicker.vue +45 -17
- package/src/components/Divider.vue +0 -4
- package/src/components/DoseCalculator.vue +0 -4
- package/src/components/DropdownButton.vue +2 -14
- package/src/components/EmptyState.vue +0 -4
- package/src/components/ExperimentCodeBadge.vue +0 -4
- package/src/components/ExperimentDataViewer.story.vue +3 -0
- package/src/components/ExperimentDataViewer.vue +33 -13
- package/src/components/ExperimentPopover.vue +12 -7
- package/src/components/ExperimentSelectorModal.vue +0 -4
- package/src/components/ExperimentTimeline.story.vue +18 -0
- package/src/components/ExperimentTimeline.vue +81 -75
- package/src/components/FileBrowserModal.story.vue +203 -0
- package/src/components/FileBrowserModal.vue +384 -0
- package/src/components/FilePicker.story.vue +44 -0
- package/src/components/FilePicker.vue +284 -0
- package/src/components/FileUploader.vue +32 -18
- package/src/components/FitPanel.vue +0 -4
- package/src/components/FormActions.story.vue +96 -0
- package/src/components/FormActions.vue +0 -4
- package/src/components/FormBuilder.vue +0 -4
- package/src/components/FormField.vue +0 -4
- package/src/components/FormulaInput.vue +0 -4
- package/src/components/GeneratedPathInput.story.vue +68 -0
- package/src/components/GeneratedPlotlyResult.story.vue +96 -0
- package/src/components/GeneratedPlotlyResult.vue +34 -69
- package/src/components/GeneratedPluginView.story.vue +145 -0
- package/src/components/GeneratedPluginView.vue +10 -10
- package/src/components/GeneratedResultRenderer.story.vue +117 -0
- package/src/components/GeneratedResultRenderer.vue +4 -9
- package/src/components/GroupAssigner.vue +67 -5
- package/src/components/IconButton.vue +0 -4
- package/src/components/InstrumentAlertLog.vue +0 -4
- package/src/components/InstrumentStateBadge.vue +0 -4
- package/src/components/InstrumentStatusCard.vue +0 -4
- package/src/components/JobsStatusTray.vue +0 -4
- package/src/components/LcmsSequenceTable.vue +81 -50
- package/src/components/LoadingSpinner.vue +0 -4
- package/src/components/MobileSupportGate.vue +0 -4
- package/src/components/MoleculeInput.vue +0 -4
- package/src/components/MultiSelect.vue +0 -4
- package/src/components/NumberInput.vue +0 -4
- package/src/components/PlateMapEditor.vue +3 -14
- package/src/components/PlotlyChart.story.vue +61 -0
- package/src/components/PlotlyChart.vue +233 -0
- package/src/components/PluginIcon.vue +0 -4
- package/src/components/ProgressBar.vue +0 -4
- package/src/components/ProtocolStepEditor.vue +2 -4
- package/src/components/RackEditor.vue +51 -70
- package/src/components/ReagentEditor.vue +0 -4
- package/src/components/ReagentList.story.vue +18 -0
- package/src/components/ReagentList.vue +127 -82
- package/src/components/ResourceCard.vue +0 -4
- package/src/components/RuntimeUpdateNotice.story.vue +49 -0
- package/src/components/RuntimeUpdateNotice.vue +4 -4
- package/src/components/SampleHierarchyTree.story.vue +18 -0
- package/src/components/SampleHierarchyTree.vue +32 -9
- package/src/components/SampleLegend.vue +2 -8
- package/src/components/SampleSelector.drag.ts +51 -0
- package/src/components/SampleSelector.story.vue +6 -0
- package/src/components/SampleSelector.tree.ts +2 -0
- package/src/components/SampleSelector.vue +49 -10
- package/src/components/SampleSelectorGroupNode.vue +19 -0
- package/src/components/ScheduleCalendar.story.vue +6 -0
- package/src/components/ScheduleCalendar.vue +82 -7
- package/src/components/ScientificNumber.vue +0 -4
- package/src/components/SectionCard.vue +0 -4
- package/src/components/SegmentedControl.vue +50 -7
- package/src/components/SequenceInput.vue +0 -4
- package/src/components/SequenceProgressBar.story.vue +110 -0
- package/src/components/SequenceProgressBar.vue +0 -4
- package/src/components/SettingsModal.vue +0 -4
- package/src/components/Skeleton.vue +0 -4
- package/src/components/SmartGroupFieldRecipe.vue +8 -6
- package/src/components/SmartGroupManual.vue +0 -4
- package/src/components/StatusIndicator.vue +0 -4
- package/src/components/StepWizard.vue +0 -4
- package/src/components/TagsInput.vue +4 -6
- package/src/components/ThemeToggle.vue +0 -4
- package/src/components/TimePicker.vue +36 -7
- package/src/components/TimeRangeInput.vue +0 -4
- package/src/components/Tooltip.story.vue +3 -3
- package/src/components/Tooltip.vue +0 -4
- package/src/components/UnitInput.vue +0 -4
- package/src/components/WellPlate.geometry.ts +60 -1
- package/src/components/WellPlate.interaction.ts +44 -0
- package/src/components/WellPlate.story.vue +8 -0
- package/src/components/WellPlate.vue +53 -7
- package/src/components/fileBrowserPresentation.ts +39 -0
- package/src/components/index.ts +5 -0
- package/src/components/internal/AppTopBarPageSelectorInternal.vue +2 -5
- package/src/components/internal/AppTopBarPillNavInternal.vue +0 -4
- package/src/components/internal/DataStateInternal.vue +74 -0
- package/src/components/internal/FileBrowserDialogInternal.vue +75 -0
- package/src/components/internal/FileBrowserListingInternal.vue +197 -0
- package/src/components/internal/FileBrowserToolbarInternal.vue +136 -0
- package/src/components/internal/FilePickerPreviewInternal.vue +100 -0
- package/src/components/internal/FilePickerTreeInternal.vue +238 -0
- package/src/components/internal/FormSectionRenderer.vue +0 -4
- package/src/components/internal/WellEditPopupInternal.vue +0 -4
- package/src/composables/controlSchemaTypes.ts +34 -0
- package/src/composables/filePicker/localFiles.ts +58 -0
- package/src/composables/filePicker/usePickerNavigation.ts +220 -0
- package/src/composables/filePicker/usePickerSelection.ts +259 -0
- package/src/composables/filePicker/validation.ts +41 -0
- package/src/composables/index.ts +17 -0
- package/src/composables/useApi.ts +57 -13
- package/src/composables/useDropdownState.ts +35 -5
- package/src/composables/useEventStream.ts +14 -2
- package/src/composables/useFileBrowser.ts +314 -0
- package/src/composables/useFileImport.ts +2 -7
- package/src/composables/useFilePicker.ts +366 -0
- package/src/composables/useGeneratedAnalysis.ts +18 -26
- package/src/composables/useListReorder.story.vue +143 -0
- package/src/composables/useListReorder.ts +242 -0
- package/src/composables/useMenuKeyboard.ts +2 -2
- package/src/composables/useOptimisticMutation.ts +1 -15
- package/src/composables/usePlatformFilePickerAdapter.ts +104 -0
- package/src/composables/usePluginClient.ts +3 -0
- package/src/composables/usePluginConfig.ts +3 -1
- package/src/composables/useRackEditor.ts +2 -11
- package/src/composables/useRequestSyncState.ts +98 -28
- package/src/composables/useResourceCrud.ts +1 -15
- package/src/composables/useScheduleDrag.ts +37 -0
- package/src/composables/useWellPainting.ts +5 -29
- package/src/composables/useWellPlateEditor.ts +1 -11
- package/src/index.ts +3 -0
- package/src/permissions.ts +48 -9
- package/src/stores/experiment.ts +2 -7
- package/src/stores/index.ts +9 -1
- package/src/stores/settings.ts +93 -1
- package/src/styles/components/audit-trail.css +5 -5
- package/src/styles/components/batch-progress-list.css +7 -0
- package/src/styles/components/color-slider.css +2 -2
- package/src/styles/components/data-state.css +30 -0
- package/src/styles/components/dataframe.css +29 -35
- package/src/styles/components/experiment-data-viewer.css +4 -4
- package/src/styles/components/experiment-timeline.css +3 -30
- package/src/styles/components/file-browser-modal.css +489 -0
- package/src/styles/components/file-picker.css +502 -0
- package/src/styles/components/form-builder.css +5 -5
- package/src/styles/components/icon-button.css +9 -0
- package/src/styles/components/lcms-sequence-table.css +16 -1
- package/src/styles/components/multi-select.css +1 -1
- package/src/styles/components/reagent-list.css +38 -31
- package/src/styles/components/sample-hierarchy-tree.css +5 -19
- package/src/styles/components/sample-selector.css +9 -2
- package/src/styles/components/schedule-calendar.css +8 -0
- package/src/styles/components/scientific-number.css +1 -1
- package/src/styles/components/well-plate.css +8 -0
- package/src/styles/index.css +11 -0
- package/src/styles/variables.css +29 -0
- package/src/templates/builderPresetControls.ts +1 -1
- package/src/templates/componentPlateHelpers.ts +3 -1
- package/src/templates/doseResponseAdapters.ts +2 -13
- package/src/templates/elisaAssayCollectionBuilder.ts +2 -2
- package/src/templates/plateMapBuilder.ts +2 -2
- package/src/templates/qpcrPlateBuilder.ts +1 -1
- package/src/templates/templateValidators.ts +1 -1
- package/src/templates/timeCourseBuilder.ts +2 -2
- package/src/templates/wellPlateScreenCollectionBuilder.ts +2 -2
- package/src/types/fileBrowserTypes.ts +85 -0
- package/src/types/filePicker.ts +72 -0
- package/src/types/index.ts +14 -0
- package/src/utils/color.ts +51 -0
- package/src/utils/errors.ts +29 -0
- package/dist/EmptyState-NBqf2_8z.js.map +0 -1
- package/dist/ExperimentPopover-CfOdh5Rm.js.map +0 -1
- package/dist/ExperimentSelectorModal-DvIagrxY.js.map +0 -1
- package/dist/SettingsModal-W3TYfnP9.js.map +0 -1
- package/dist/components-B80gV0P6.js.map +0 -1
- package/dist/composables/autoGroupConstants.d.ts +0 -1
- package/dist/composables/autoGroupGrouping.d.ts +0 -3
- package/dist/composables/useAutoGroupInputSources.d.ts +0 -32
- package/dist/composables-C8mmD5ta.js.map +0 -1
- package/dist/experiment-Y9Iz7KYi.js.map +0 -1
- package/dist/experiment-utils-DV3DrvE_.js.map +0 -1
- package/dist/templates/builderDefaults.d.ts +0 -1
- package/dist/templates/plateGeometry.d.ts +0 -4
- package/dist/templates-CK72aKO1.js.map +0 -1
- package/dist/useApi-CDBq6z23.js.map +0 -1
- package/dist/useControlSchema-_OVhavKq.js.map +0 -1
- package/dist/useDropdownState-D5G4UvWd.js.map +0 -1
- package/dist/useProtocolTemplates-Dq5Pzwyd.js.map +0 -1
- package/src/__tests__/composables/useAutoGroupInputSources.test.ts +0 -127
- package/src/composables/autoGroupConstants.ts +0 -4
- package/src/composables/autoGroupGrouping.ts +0 -148
- package/src/composables/useAutoGroupInputSources.ts +0 -147
- package/src/templates/builderDefaults.ts +0 -11
- package/src/templates/plateGeometry.ts +0 -62
- /package/dist/__tests__/{composables/useAutoGroupInputSources.test.d.ts → apiErrors.test.d.ts} +0 -0
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import GeneratedPlotlyResult from './GeneratedPlotlyResult.vue'
|
|
3
|
+
|
|
4
|
+
const scatterSpec: Record<string, unknown> = {
|
|
5
|
+
data: [
|
|
6
|
+
{
|
|
7
|
+
type: 'scatter',
|
|
8
|
+
mode: 'markers',
|
|
9
|
+
name: 'Control',
|
|
10
|
+
x: [1.2, 2.4, 3.1, 4.8, 5.5, 6.9],
|
|
11
|
+
y: [0.9, 1.8, 2.6, 3.9, 4.4, 5.8],
|
|
12
|
+
marker: { size: 9 },
|
|
13
|
+
},
|
|
14
|
+
{
|
|
15
|
+
type: 'scatter',
|
|
16
|
+
mode: 'markers',
|
|
17
|
+
name: 'Treated',
|
|
18
|
+
x: [1.1, 2.2, 3.4, 4.5, 5.9, 6.4],
|
|
19
|
+
y: [2.1, 3.4, 3.9, 5.2, 6.4, 7.1],
|
|
20
|
+
marker: { size: 9 },
|
|
21
|
+
},
|
|
22
|
+
],
|
|
23
|
+
layout: {
|
|
24
|
+
margin: { t: 24, r: 16, b: 40, l: 48 },
|
|
25
|
+
xaxis: { title: 'log2 intensity (control)' },
|
|
26
|
+
yaxis: { title: 'log2 intensity (treated)' },
|
|
27
|
+
},
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
const barSpec: Record<string, unknown> = {
|
|
31
|
+
data: [
|
|
32
|
+
{
|
|
33
|
+
type: 'bar',
|
|
34
|
+
x: ['Glycolysis', 'TCA', 'PPP', 'Urea cycle'],
|
|
35
|
+
y: [12, 27, 8, 4],
|
|
36
|
+
},
|
|
37
|
+
],
|
|
38
|
+
layout: { margin: { t: 24, r: 16, b: 40, l: 48 } },
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
// Not a valid Plotly spec — exercises the static-image fallback branch.
|
|
42
|
+
const brokenSpec: Record<string, unknown> = { data: 'not-an-array' }
|
|
43
|
+
|
|
44
|
+
const PIXEL_PNG
|
|
45
|
+
= 'iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mP8z8BQDwAEhQGAhKmMIQAAAABJRU5ErkJggg=='
|
|
46
|
+
|
|
47
|
+
function initState() {
|
|
48
|
+
return { chart: 'scatter' as 'scatter' | 'bar' }
|
|
49
|
+
}
|
|
50
|
+
</script>
|
|
51
|
+
|
|
52
|
+
<template>
|
|
53
|
+
<Story title="Workflow/GeneratedPlotlyResult">
|
|
54
|
+
<Variant title="Playground" :init-state="initState">
|
|
55
|
+
<template #default="{ state }">
|
|
56
|
+
<div style="padding: 2rem; max-width: 720px;">
|
|
57
|
+
<GeneratedPlotlyResult :spec="state.chart === 'bar' ? barSpec : scatterSpec" />
|
|
58
|
+
</div>
|
|
59
|
+
</template>
|
|
60
|
+
|
|
61
|
+
<template #controls="{ state }">
|
|
62
|
+
<HstSelect
|
|
63
|
+
v-model="state.chart"
|
|
64
|
+
title="Chart"
|
|
65
|
+
:options="[
|
|
66
|
+
{ label: 'scatter', value: 'scatter' },
|
|
67
|
+
{ label: 'bar', value: 'bar' },
|
|
68
|
+
]"
|
|
69
|
+
/>
|
|
70
|
+
</template>
|
|
71
|
+
</Variant>
|
|
72
|
+
|
|
73
|
+
<Variant title="Scatter">
|
|
74
|
+
<div style="padding: 2rem; max-width: 720px;">
|
|
75
|
+
<GeneratedPlotlyResult :spec="scatterSpec" />
|
|
76
|
+
</div>
|
|
77
|
+
</Variant>
|
|
78
|
+
|
|
79
|
+
<Variant title="Bar">
|
|
80
|
+
<div style="padding: 2rem; max-width: 720px;">
|
|
81
|
+
<GeneratedPlotlyResult :spec="barSpec" />
|
|
82
|
+
</div>
|
|
83
|
+
</Variant>
|
|
84
|
+
|
|
85
|
+
<Variant title="Render failure → PNG fallback">
|
|
86
|
+
<!-- When Plotly cannot render the spec the component swaps in the
|
|
87
|
+
server-rendered static image, if the job supplied one. -->
|
|
88
|
+
<div style="padding: 2rem; max-width: 720px;">
|
|
89
|
+
<GeneratedPlotlyResult
|
|
90
|
+
:spec="brokenSpec"
|
|
91
|
+
:fallback="{ media_type: 'image/png', data: PIXEL_PNG }"
|
|
92
|
+
/>
|
|
93
|
+
</div>
|
|
94
|
+
</Variant>
|
|
95
|
+
</Story>
|
|
96
|
+
</template>
|
|
@@ -1,87 +1,52 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
|
-
import { nextTick, onBeforeUnmount, onMounted, ref, watch } from 'vue'
|
|
3
2
|
import type * as PlotlyType from 'plotly.js'
|
|
3
|
+
import { computed, toRaw } from 'vue'
|
|
4
4
|
|
|
5
|
-
import
|
|
5
|
+
import PlotlyChart from './PlotlyChart.vue'
|
|
6
6
|
|
|
7
7
|
const props = defineProps<{
|
|
8
8
|
spec: Record<string, unknown>
|
|
9
9
|
fallback?: { media_type: string; data: string }
|
|
10
10
|
}>()
|
|
11
11
|
|
|
12
|
-
const
|
|
13
|
-
const
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
async function loadPlotly(): Promise<typeof PlotlyType> {
|
|
17
|
-
const module = await import('plotly.js-dist-min')
|
|
18
|
-
return ('default' in module ? module.default : module) as unknown as typeof PlotlyType
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
async function renderChart(): Promise<void> {
|
|
22
|
-
if (!chartElement.value) return
|
|
23
|
-
failed.value = false
|
|
24
|
-
await nextTick()
|
|
25
|
-
try {
|
|
26
|
-
const renderer = plotly ?? await loadPlotly()
|
|
27
|
-
plotly = renderer
|
|
28
|
-
const data = Array.isArray(props.spec.data) ? props.spec.data : []
|
|
29
|
-
const layout = props.spec.layout && typeof props.spec.layout === 'object'
|
|
30
|
-
? props.spec.layout
|
|
31
|
-
: {}
|
|
32
|
-
await renderer.react(
|
|
33
|
-
chartElement.value,
|
|
34
|
-
data as PlotlyType.Data[],
|
|
35
|
-
layout as Partial<PlotlyType.Layout>,
|
|
36
|
-
{ responsive: true, displaylogo: false },
|
|
37
|
-
)
|
|
38
|
-
failed.value = false
|
|
39
|
-
} catch {
|
|
40
|
-
failed.value = true
|
|
41
|
-
}
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
onMounted(renderChart)
|
|
45
|
-
watch(() => props.spec, async () => {
|
|
46
|
-
await nextTick()
|
|
47
|
-
await renderChart()
|
|
48
|
-
})
|
|
49
|
-
onBeforeUnmount(() => {
|
|
50
|
-
if (plotly && chartElement.value) plotly.purge(chartElement.value)
|
|
12
|
+
const data = computed<PlotlyType.Data[]>(() => {
|
|
13
|
+
const traces = toRaw(props.spec).data
|
|
14
|
+
return Array.isArray(traces) ? [...toRaw(traces)] as PlotlyType.Data[] : []
|
|
51
15
|
})
|
|
16
|
+
const layout = computed<Partial<PlotlyType.Layout>>(() => (
|
|
17
|
+
props.spec.layout && typeof props.spec.layout === 'object'
|
|
18
|
+
? props.spec.layout as Partial<PlotlyType.Layout>
|
|
19
|
+
: {}
|
|
20
|
+
))
|
|
21
|
+
const config = computed<Partial<PlotlyType.Config>>(() => (
|
|
22
|
+
props.spec.config && typeof props.spec.config === 'object'
|
|
23
|
+
? props.spec.config as Partial<PlotlyType.Config>
|
|
24
|
+
: {}
|
|
25
|
+
))
|
|
52
26
|
</script>
|
|
53
27
|
|
|
54
28
|
<template>
|
|
55
|
-
<
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
>
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
<div
|
|
70
|
-
ref="chartElement"
|
|
71
|
-
v-show="!failed"
|
|
72
|
-
class="mint-generated-result__plotly"
|
|
73
|
-
aria-label="Interactive Plotly chart"
|
|
74
|
-
/>
|
|
75
|
-
</ChartContainer>
|
|
29
|
+
<PlotlyChart
|
|
30
|
+
title="Interactive chart"
|
|
31
|
+
:data="data"
|
|
32
|
+
:layout="layout"
|
|
33
|
+
:config="config"
|
|
34
|
+
>
|
|
35
|
+
<template v-if="fallback" #error>
|
|
36
|
+
<img
|
|
37
|
+
class="mint-generated-result__image"
|
|
38
|
+
:src="`data:${fallback.media_type};base64,${fallback.data}`"
|
|
39
|
+
alt="Static Plotly chart fallback"
|
|
40
|
+
>
|
|
41
|
+
</template>
|
|
42
|
+
</PlotlyChart>
|
|
76
43
|
</template>
|
|
77
44
|
|
|
78
45
|
<style scoped>
|
|
79
|
-
.mint-generated-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
background: var(--color-danger-bg, var(--color-bg-secondary));
|
|
85
|
-
color: var(--color-danger-text, var(--color-text-primary));
|
|
46
|
+
.mint-generated-result__image {
|
|
47
|
+
display: block;
|
|
48
|
+
max-width: 100%;
|
|
49
|
+
height: auto;
|
|
50
|
+
margin: 0 auto;
|
|
86
51
|
}
|
|
87
52
|
</style>
|
|
@@ -0,0 +1,145 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import GeneratedPluginView from './GeneratedPluginView.vue'
|
|
3
|
+
import type { GeneratedAnalysisTransport } from '../composables/useGeneratedAnalysis'
|
|
4
|
+
import type { GeneratedAnalysisManifest } from '../types/generated-ui'
|
|
5
|
+
|
|
6
|
+
const manifest: GeneratedAnalysisManifest = {
|
|
7
|
+
schema_version: '1',
|
|
8
|
+
plugin: {
|
|
9
|
+
name: 'peak-qc',
|
|
10
|
+
version: '1.2.0',
|
|
11
|
+
description: 'Peak-picking quality control',
|
|
12
|
+
routes_prefix: '/api/peak-qc',
|
|
13
|
+
},
|
|
14
|
+
ui: {
|
|
15
|
+
title: 'Peak QC',
|
|
16
|
+
description: 'Score peak-picking output and flag features that need review.',
|
|
17
|
+
},
|
|
18
|
+
jobs: [
|
|
19
|
+
{
|
|
20
|
+
id: 'score-features',
|
|
21
|
+
title: 'Score features',
|
|
22
|
+
description: 'Compute RSD, blank ratio and detection rate for every feature.',
|
|
23
|
+
cpu: 4,
|
|
24
|
+
input_schema: {
|
|
25
|
+
type: 'object',
|
|
26
|
+
title: 'Scoring parameters',
|
|
27
|
+
properties: {
|
|
28
|
+
rsd_threshold: {
|
|
29
|
+
type: 'number',
|
|
30
|
+
title: 'QC RSD threshold',
|
|
31
|
+
description: 'Features above this relative standard deviation are flagged.',
|
|
32
|
+
default: 0.3,
|
|
33
|
+
minimum: 0,
|
|
34
|
+
maximum: 1,
|
|
35
|
+
},
|
|
36
|
+
blank_ratio: {
|
|
37
|
+
type: 'number',
|
|
38
|
+
title: 'Minimum blank ratio',
|
|
39
|
+
default: 3,
|
|
40
|
+
minimum: 1,
|
|
41
|
+
},
|
|
42
|
+
drop_flagged: {
|
|
43
|
+
type: 'boolean',
|
|
44
|
+
title: 'Drop flagged features',
|
|
45
|
+
default: false,
|
|
46
|
+
},
|
|
47
|
+
},
|
|
48
|
+
required: ['rsd_threshold'],
|
|
49
|
+
},
|
|
50
|
+
output_schema: { type: 'object' },
|
|
51
|
+
},
|
|
52
|
+
{
|
|
53
|
+
id: 'align-batches',
|
|
54
|
+
title: 'Align batches',
|
|
55
|
+
description: 'Retention-time align acquisition batches before merging.',
|
|
56
|
+
cpu: 8,
|
|
57
|
+
input_schema: {
|
|
58
|
+
type: 'object',
|
|
59
|
+
properties: {
|
|
60
|
+
tolerance_seconds: { type: 'number', title: 'RT tolerance (s)', default: 6 },
|
|
61
|
+
reference_batch: { type: 'string', title: 'Reference batch', default: 'batch-1' },
|
|
62
|
+
},
|
|
63
|
+
},
|
|
64
|
+
output_schema: { type: 'object' },
|
|
65
|
+
},
|
|
66
|
+
],
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
const session = {
|
|
70
|
+
id: 'sess_story',
|
|
71
|
+
tab_id: 'tab_story',
|
|
72
|
+
created_at: new Date().toISOString(),
|
|
73
|
+
last_seen_at: new Date().toISOString(),
|
|
74
|
+
active_job_ids: [],
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
function json(body: unknown): Response {
|
|
78
|
+
return new Response(JSON.stringify(body), {
|
|
79
|
+
status: 200,
|
|
80
|
+
headers: { 'Content-Type': 'application/json' },
|
|
81
|
+
})
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
/** Serves the manifest, one session and an empty job list — no network. */
|
|
85
|
+
const readyTransport: GeneratedAnalysisTransport = async (input) => {
|
|
86
|
+
const url = String(input)
|
|
87
|
+
if (url.includes('/generated/manifest')) return json(manifest)
|
|
88
|
+
if (url.includes('/jobs/sessions')) return json({ sessions: [session] })
|
|
89
|
+
if (url.includes('/jobs')) return json({ jobs: [] })
|
|
90
|
+
return json({})
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
/** Never settles, so the workspace stays in its loading state. */
|
|
94
|
+
const loadingTransport: GeneratedAnalysisTransport = () => new Promise<Response>(() => {})
|
|
95
|
+
|
|
96
|
+
/** Fails the manifest request, so the workspace surfaces its error banner. */
|
|
97
|
+
const failingTransport: GeneratedAnalysisTransport = async () => (
|
|
98
|
+
new Response(JSON.stringify({ detail: 'Plugin runtime is not reachable' }), {
|
|
99
|
+
status: 503,
|
|
100
|
+
headers: { 'Content-Type': 'application/json' },
|
|
101
|
+
})
|
|
102
|
+
)
|
|
103
|
+
|
|
104
|
+
function initState() {
|
|
105
|
+
return { showStandaloneLabel: false }
|
|
106
|
+
}
|
|
107
|
+
</script>
|
|
108
|
+
|
|
109
|
+
<template>
|
|
110
|
+
<Story title="Workflow/GeneratedPluginView">
|
|
111
|
+
<Variant title="Playground" :init-state="initState">
|
|
112
|
+
<template #default="{ state }">
|
|
113
|
+
<div style="height: 42rem;">
|
|
114
|
+
<GeneratedPluginView
|
|
115
|
+
base-url="/story/peak-qc"
|
|
116
|
+
:transport="readyTransport"
|
|
117
|
+
:show-standalone-label="state.showStandaloneLabel"
|
|
118
|
+
/>
|
|
119
|
+
</div>
|
|
120
|
+
</template>
|
|
121
|
+
|
|
122
|
+
<template #controls="{ state }">
|
|
123
|
+
<HstCheckbox v-model="state.showStandaloneLabel" title="Standalone label" />
|
|
124
|
+
</template>
|
|
125
|
+
</Variant>
|
|
126
|
+
|
|
127
|
+
<Variant title="Ready — two job definitions">
|
|
128
|
+
<div style="height: 42rem;">
|
|
129
|
+
<GeneratedPluginView base-url="/story/peak-qc" :transport="readyTransport" />
|
|
130
|
+
</div>
|
|
131
|
+
</Variant>
|
|
132
|
+
|
|
133
|
+
<Variant title="Loading">
|
|
134
|
+
<div style="height: 42rem;">
|
|
135
|
+
<GeneratedPluginView base-url="/story/loading" :transport="loadingTransport" />
|
|
136
|
+
</div>
|
|
137
|
+
</Variant>
|
|
138
|
+
|
|
139
|
+
<Variant title="Runtime unreachable">
|
|
140
|
+
<div style="height: 42rem;">
|
|
141
|
+
<GeneratedPluginView base-url="/story/failing" :transport="failingTransport" />
|
|
142
|
+
</div>
|
|
143
|
+
</Variant>
|
|
144
|
+
</Story>
|
|
145
|
+
</template>
|
|
@@ -207,7 +207,7 @@ onMounted(() => {
|
|
|
207
207
|
min-width: 0;
|
|
208
208
|
min-height: calc(100vh - 5rem);
|
|
209
209
|
padding: clamp(1rem, 2.5vw, 2.5rem);
|
|
210
|
-
background: var(--
|
|
210
|
+
background: var(--bg-primary);
|
|
211
211
|
}
|
|
212
212
|
|
|
213
213
|
.mint-generated-workspace__loading {
|
|
@@ -216,7 +216,7 @@ onMounted(() => {
|
|
|
216
216
|
align-items: center;
|
|
217
217
|
justify-content: center;
|
|
218
218
|
gap: 0.75rem;
|
|
219
|
-
color: var(--
|
|
219
|
+
color: var(--text-secondary);
|
|
220
220
|
}
|
|
221
221
|
|
|
222
222
|
.mint-generated-workspace__header {
|
|
@@ -230,19 +230,19 @@ onMounted(() => {
|
|
|
230
230
|
|
|
231
231
|
.mint-generated-workspace__header h1 {
|
|
232
232
|
margin: 0;
|
|
233
|
-
color: var(--
|
|
233
|
+
color: var(--text-primary);
|
|
234
234
|
font-size: clamp(1.35rem, 2vw, 1.8rem);
|
|
235
235
|
line-height: 1.2;
|
|
236
236
|
}
|
|
237
237
|
|
|
238
238
|
.mint-generated-workspace__header p:not(.mint-generated-workspace__eyebrow) {
|
|
239
239
|
margin: 0.4rem 0 0;
|
|
240
|
-
color: var(--
|
|
240
|
+
color: var(--text-secondary);
|
|
241
241
|
}
|
|
242
242
|
|
|
243
243
|
.mint-generated-workspace__eyebrow {
|
|
244
244
|
margin: 0 0 0.35rem;
|
|
245
|
-
color: var(--
|
|
245
|
+
color: var(--text-muted);
|
|
246
246
|
font-size: 0.72rem;
|
|
247
247
|
font-weight: 700;
|
|
248
248
|
letter-spacing: 0.08em;
|
|
@@ -258,10 +258,10 @@ onMounted(() => {
|
|
|
258
258
|
|
|
259
259
|
.mint-generated-workspace__resources span {
|
|
260
260
|
padding: 0.3rem 0.55rem;
|
|
261
|
-
border: 1px solid var(--color
|
|
261
|
+
border: 1px solid var(--border-color);
|
|
262
262
|
border-radius: 999px;
|
|
263
|
-
background: var(--
|
|
264
|
-
color: var(--
|
|
263
|
+
background: var(--bg-secondary);
|
|
264
|
+
color: var(--text-secondary);
|
|
265
265
|
font-size: 0.75rem;
|
|
266
266
|
font-weight: 600;
|
|
267
267
|
}
|
|
@@ -271,9 +271,9 @@ onMounted(() => {
|
|
|
271
271
|
min-height: 24rem;
|
|
272
272
|
margin: 0 auto;
|
|
273
273
|
padding: clamp(1rem, 2vw, 1.75rem);
|
|
274
|
-
border: 1px solid var(--color
|
|
274
|
+
border: 1px solid var(--border-color);
|
|
275
275
|
border-radius: 1rem;
|
|
276
|
-
background: var(--
|
|
276
|
+
background: var(--bg-secondary);
|
|
277
277
|
box-shadow: var(--shadow-sm);
|
|
278
278
|
}
|
|
279
279
|
|
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import GeneratedResultRenderer from './GeneratedResultRenderer.vue'
|
|
3
|
+
import type { GeneratedAnalysisResult } from '../types/generated-ui'
|
|
4
|
+
|
|
5
|
+
const textResult: GeneratedAnalysisResult = {
|
|
6
|
+
kind: 'text',
|
|
7
|
+
text: 'Peak integration finished: 1,284 features across 96 samples, 12 flagged for manual review.',
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
const jsonResult: GeneratedAnalysisResult = {
|
|
11
|
+
kind: 'json',
|
|
12
|
+
value: {
|
|
13
|
+
method: 'HILIC_neg_12min',
|
|
14
|
+
features: 1284,
|
|
15
|
+
qc: { rsd_median: 0.041, blanks_removed: 37 },
|
|
16
|
+
flagged: ['M241T118', 'M317T204'],
|
|
17
|
+
},
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
const tableResult: GeneratedAnalysisResult = {
|
|
21
|
+
kind: 'table',
|
|
22
|
+
columns: ['feature_id', 'mz', 'retention_time', 'fold_change', 'p_value'],
|
|
23
|
+
rows: [
|
|
24
|
+
{ feature_id: 'M180T204', mz: 180.0634, retention_time: 3.42, fold_change: 2.14, p_value: 0.0012 },
|
|
25
|
+
{ feature_id: 'M241T118', mz: 241.0311, retention_time: 1.97, fold_change: -1.83, p_value: 0.0044 },
|
|
26
|
+
{ feature_id: 'M317T204', mz: 317.0521, retention_time: 3.41, fold_change: 1.07, p_value: 0.2310 },
|
|
27
|
+
{ feature_id: 'M146T092', mz: 146.0453, retention_time: 1.53, fold_change: -3.02, p_value: 0.0001 },
|
|
28
|
+
],
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
// 1x1 transparent PNG — enough to exercise the image branch without a fixture.
|
|
32
|
+
const PIXEL_PNG
|
|
33
|
+
= 'iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mP8z8BQDwAEhQGAhKmMIQAAAABJRU5ErkJggg=='
|
|
34
|
+
|
|
35
|
+
const imageResult: GeneratedAnalysisResult = {
|
|
36
|
+
kind: 'image',
|
|
37
|
+
media_type: 'image/png',
|
|
38
|
+
data: PIXEL_PNG,
|
|
39
|
+
alt: 'Static QC overview rendered by the plugin',
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
const artifactResult: GeneratedAnalysisResult = {
|
|
43
|
+
kind: 'artifact',
|
|
44
|
+
id: 'art_01J9',
|
|
45
|
+
name: 'peak_table.parquet',
|
|
46
|
+
media_type: 'application/vnd.apache.parquet',
|
|
47
|
+
size: 4_812_390,
|
|
48
|
+
download_url: '#download',
|
|
49
|
+
managed: true,
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
type ResultKind = 'text' | 'json' | 'table' | 'image' | 'artifact'
|
|
53
|
+
|
|
54
|
+
const kinds: ResultKind[] = ['text', 'json', 'table', 'image', 'artifact']
|
|
55
|
+
|
|
56
|
+
const byKind: Record<ResultKind, GeneratedAnalysisResult> = {
|
|
57
|
+
text: textResult,
|
|
58
|
+
json: jsonResult,
|
|
59
|
+
table: tableResult,
|
|
60
|
+
image: imageResult,
|
|
61
|
+
artifact: artifactResult,
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
function initState() {
|
|
65
|
+
return { kind: 'table' as ResultKind }
|
|
66
|
+
}
|
|
67
|
+
</script>
|
|
68
|
+
|
|
69
|
+
<template>
|
|
70
|
+
<Story title="Workflow/GeneratedResultRenderer">
|
|
71
|
+
<Variant title="Playground" :init-state="initState">
|
|
72
|
+
<template #default="{ state }">
|
|
73
|
+
<div style="padding: 2rem; max-width: 720px;">
|
|
74
|
+
<GeneratedResultRenderer :result="byKind[state.kind as ResultKind]" />
|
|
75
|
+
</div>
|
|
76
|
+
</template>
|
|
77
|
+
|
|
78
|
+
<template #controls="{ state }">
|
|
79
|
+
<HstSelect
|
|
80
|
+
v-model="state.kind"
|
|
81
|
+
title="Result kind"
|
|
82
|
+
:options="kinds.map(k => ({ label: k, value: k }))"
|
|
83
|
+
/>
|
|
84
|
+
</template>
|
|
85
|
+
</Variant>
|
|
86
|
+
|
|
87
|
+
<Variant title="Text">
|
|
88
|
+
<div style="padding: 2rem; max-width: 720px;">
|
|
89
|
+
<GeneratedResultRenderer :result="textResult" />
|
|
90
|
+
</div>
|
|
91
|
+
</Variant>
|
|
92
|
+
|
|
93
|
+
<Variant title="Table">
|
|
94
|
+
<div style="padding: 2rem; max-width: 720px;">
|
|
95
|
+
<GeneratedResultRenderer :result="tableResult" />
|
|
96
|
+
</div>
|
|
97
|
+
</Variant>
|
|
98
|
+
|
|
99
|
+
<Variant title="JSON">
|
|
100
|
+
<div style="padding: 2rem; max-width: 720px;">
|
|
101
|
+
<GeneratedResultRenderer :result="jsonResult" />
|
|
102
|
+
</div>
|
|
103
|
+
</Variant>
|
|
104
|
+
|
|
105
|
+
<Variant title="Image">
|
|
106
|
+
<div style="padding: 2rem; max-width: 720px;">
|
|
107
|
+
<GeneratedResultRenderer :result="imageResult" />
|
|
108
|
+
</div>
|
|
109
|
+
</Variant>
|
|
110
|
+
|
|
111
|
+
<Variant title="Artifact download">
|
|
112
|
+
<div style="padding: 2rem; max-width: 720px;">
|
|
113
|
+
<GeneratedResultRenderer :result="artifactResult" />
|
|
114
|
+
</div>
|
|
115
|
+
</Variant>
|
|
116
|
+
</Story>
|
|
117
|
+
</template>
|
|
@@ -101,7 +101,7 @@ function humanize(value: string): string {
|
|
|
101
101
|
.mint-generated-result__text,
|
|
102
102
|
.mint-generated-result__json {
|
|
103
103
|
margin: 0;
|
|
104
|
-
color: var(--
|
|
104
|
+
color: var(--text-primary);
|
|
105
105
|
}
|
|
106
106
|
|
|
107
107
|
.mint-generated-result__text {
|
|
@@ -113,9 +113,9 @@ function humanize(value: string): string {
|
|
|
113
113
|
.mint-generated-result__json {
|
|
114
114
|
overflow: auto;
|
|
115
115
|
padding: 1rem;
|
|
116
|
-
border: 1px solid var(--color
|
|
116
|
+
border: 1px solid var(--border-color);
|
|
117
117
|
border-radius: 0.75rem;
|
|
118
|
-
background: var(--
|
|
118
|
+
background: var(--bg-secondary);
|
|
119
119
|
font-size: 0.8125rem;
|
|
120
120
|
line-height: 1.55;
|
|
121
121
|
white-space: pre-wrap;
|
|
@@ -128,18 +128,13 @@ function humanize(value: string): string {
|
|
|
128
128
|
margin: 0 auto;
|
|
129
129
|
}
|
|
130
130
|
|
|
131
|
-
.mint-generated-result__plotly {
|
|
132
|
-
width: 100%;
|
|
133
|
-
min-height: 24rem;
|
|
134
|
-
}
|
|
135
|
-
|
|
136
131
|
.mint-generated-result__artifact {
|
|
137
132
|
display: flex;
|
|
138
133
|
align-items: center;
|
|
139
134
|
justify-content: space-between;
|
|
140
135
|
gap: 1rem;
|
|
141
136
|
padding: 1rem;
|
|
142
|
-
border: 1px solid var(--color
|
|
137
|
+
border: 1px solid var(--border-color);
|
|
143
138
|
border-radius: 0.75rem;
|
|
144
139
|
color: var(--color-primary);
|
|
145
140
|
text-decoration: none;
|