@morscherlab/mint-sdk 1.0.0-alpha.2
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 +326 -0
- package/dist/__stories__/experiment-helpers.d.ts +25 -0
- package/dist/__tests__/components/AppLayout.test.d.ts +1 -0
- package/dist/__tests__/components/AppSidebar.test.d.ts +1 -0
- package/dist/__tests__/components/AppTopBar.test.d.ts +1 -0
- package/dist/__tests__/components/BaseInput.test.d.ts +1 -0
- package/dist/__tests__/components/BasePill.test.d.ts +1 -0
- package/dist/__tests__/components/Calendar.test.d.ts +1 -0
- package/dist/__tests__/components/CollapsibleCard.test.d.ts +1 -0
- package/dist/__tests__/components/DataFrame.test.d.ts +1 -0
- package/dist/__tests__/components/DropdownButton.test.d.ts +1 -0
- package/dist/__tests__/composables/formBuilderRegistry.test.d.ts +1 -0
- package/dist/__tests__/composables/useAppExperiment.test.d.ts +1 -0
- package/dist/__tests__/composables/useAuth.test.d.ts +1 -0
- package/dist/__tests__/composables/useAutoGroup.test.d.ts +1 -0
- package/dist/__tests__/composables/useExperimentData.test.d.ts +13 -0
- package/dist/__tests__/composables/useExperimentSave.test.d.ts +1 -0
- package/dist/__tests__/composables/useForm.test.d.ts +1 -0
- package/dist/__tests__/composables/useFormBuilder.test.d.ts +1 -0
- package/dist/__tests__/composables/usePlatformContext.test.d.ts +1 -0
- package/dist/__tests__/composables/usePluginApi.test.d.ts +13 -0
- package/dist/__tests__/composables/usePluginConfig.test.d.ts +14 -0
- package/dist/__tests__/utils/color.test.d.ts +1 -0
- package/dist/auth-BYmxZdJl.js +297 -0
- package/dist/auth-BYmxZdJl.js.map +1 -0
- package/dist/components/AlertBox.vue.d.ts +34 -0
- package/dist/components/AppAvatarMenu.vue.d.ts +58 -0
- package/dist/components/AppContainer.vue.d.ts +28 -0
- package/dist/components/AppLayout.vue.d.ts +31 -0
- package/dist/components/AppPageSelector.vue.d.ts +43 -0
- package/dist/components/AppPillNav.vue.d.ts +11 -0
- package/dist/components/AppPluginSwitcher.vue.d.ts +38 -0
- package/dist/components/AppSidebar.vue.d.ts +47 -0
- package/dist/components/AppTopBar.vue.d.ts +111 -0
- package/dist/components/AuditTrail.vue.d.ts +38 -0
- package/dist/components/AutoGroupModal.vue.d.ts +124 -0
- package/dist/components/Avatar.vue.d.ts +14 -0
- package/dist/components/BaseButton.vue.d.ts +37 -0
- package/dist/components/BaseCheckbox.vue.d.ts +17 -0
- package/dist/components/BaseInput.vue.d.ts +34 -0
- package/dist/components/BaseModal.vue.d.ts +46 -0
- package/dist/components/BasePill.vue.d.ts +57 -0
- package/dist/components/BaseRadioGroup.vue.d.ts +21 -0
- package/dist/components/BaseSelect.vue.d.ts +20 -0
- package/dist/components/BaseSlider.vue.d.ts +22 -0
- package/dist/components/BaseTabs.vue.d.ts +14 -0
- package/dist/components/BaseTextarea.vue.d.ts +30 -0
- package/dist/components/BaseToggle.vue.d.ts +19 -0
- package/dist/components/BatchProgressList.vue.d.ts +43 -0
- package/dist/components/Breadcrumb.vue.d.ts +33 -0
- package/dist/components/Calendar.vue.d.ts +107 -0
- package/dist/components/ChartContainer.vue.d.ts +31 -0
- package/dist/components/ChemicalFormula.vue.d.ts +8 -0
- package/dist/components/CollapsibleCard.vue.d.ts +41 -0
- package/dist/components/ColorSlider.vue.d.ts +34 -0
- package/dist/components/ConcentrationInput.vue.d.ts +25 -0
- package/dist/components/ConfirmDialog.vue.d.ts +42 -0
- package/dist/components/DataFrame.vue.d.ts +107 -0
- package/dist/components/DatePicker.vue.d.ts +25 -0
- package/dist/components/DateTimePicker.vue.d.ts +30 -0
- package/dist/components/Divider.vue.d.ts +14 -0
- package/dist/components/DoseCalculator.vue.d.ts +19 -0
- package/dist/components/DropdownButton.vue.d.ts +47 -0
- package/dist/components/EmptyState.vue.d.ts +36 -0
- package/dist/components/ExperimentCodeBadge.vue.d.ts +14 -0
- package/dist/components/ExperimentDataViewer.vue.d.ts +29 -0
- package/dist/components/ExperimentPopover.vue.d.ts +32 -0
- package/dist/components/ExperimentSelectorModal.vue.d.ts +28 -0
- package/dist/components/ExperimentTimeline.vue.d.ts +44 -0
- package/dist/components/FileUploader.vue.d.ts +40 -0
- package/dist/components/FitPanel.vue.d.ts +46 -0
- package/dist/components/FormActions.vue.d.ts +33 -0
- package/dist/components/FormBuilder.vue.d.ts +287 -0
- package/dist/components/FormField.vue.d.ts +28 -0
- package/dist/components/FormFieldRenderer.vue.d.ts +31 -0
- package/dist/components/FormSection.vue.d.ts +43 -0
- package/dist/components/FormulaInput.vue.d.ts +25 -0
- package/dist/components/GroupAssigner.vue.d.ts +25 -0
- package/dist/components/GroupingModal.vue.d.ts +12 -0
- package/dist/components/IconButton.vue.d.ts +34 -0
- package/dist/components/LoadingSpinner.vue.d.ts +12 -0
- package/dist/components/MoleculeInput.vue.d.ts +27 -0
- package/dist/components/MultiSelect.vue.d.ts +19 -0
- package/dist/components/NumberInput.vue.d.ts +22 -0
- package/dist/components/PlateMapEditor.vue.d.ts +50 -0
- package/dist/components/ProgressBar.vue.d.ts +23 -0
- package/dist/components/ProtocolStepEditor.vue.d.ts +24 -0
- package/dist/components/RackEditor.vue.d.ts +40 -0
- package/dist/components/ReagentEditor.vue.d.ts +30 -0
- package/dist/components/ReagentList.vue.d.ts +32 -0
- package/dist/components/ResourceCard.vue.d.ts +50 -0
- package/dist/components/SampleHierarchyTree.vue.d.ts +26 -0
- package/dist/components/SampleLegend.vue.d.ts +32 -0
- package/dist/components/SampleSelector.vue.d.ts +29 -0
- package/dist/components/ScheduleCalendar.vue.d.ts +110 -0
- package/dist/components/ScientificNumber.vue.d.ts +14 -0
- package/dist/components/SegmentedControl.vue.d.ts +20 -0
- package/dist/components/SequenceInput.vue.d.ts +54 -0
- package/dist/components/SettingsButton.vue.d.ts +30 -0
- package/dist/components/SettingsModal.vue.d.ts +36 -0
- package/dist/components/Skeleton.vue.d.ts +11 -0
- package/dist/components/StatusIndicator.vue.d.ts +13 -0
- package/dist/components/StepWizard.vue.d.ts +65 -0
- package/dist/components/TagsInput.vue.d.ts +39 -0
- package/dist/components/ThemeToggle.vue.d.ts +7 -0
- package/dist/components/TimePicker.vue.d.ts +29 -0
- package/dist/components/TimeRangeInput.vue.d.ts +27 -0
- package/dist/components/ToastNotification.vue.d.ts +2 -0
- package/dist/components/Tooltip.vue.d.ts +35 -0
- package/dist/components/UnitInput.vue.d.ts +39 -0
- package/dist/components/WellEditPopup.vue.d.ts +25 -0
- package/dist/components/WellPlate.vue.d.ts +73 -0
- package/dist/components/index.d.ts +87 -0
- package/dist/components/index.js +3 -0
- package/dist/components-CKf-UpGi.js +15089 -0
- package/dist/components-CKf-UpGi.js.map +1 -0
- package/dist/composables/experiment-utils.d.ts +8 -0
- package/dist/composables/formBuilderRegistry.d.ts +13 -0
- package/dist/composables/index.d.ts +28 -0
- package/dist/composables/index.js +3 -0
- package/dist/composables/useApi.d.ts +20 -0
- package/dist/composables/useAppExperiment.d.ts +37 -0
- package/dist/composables/useAsync.d.ts +128 -0
- package/dist/composables/useAuth.d.ts +47 -0
- package/dist/composables/useAutoGroup.d.ts +106 -0
- package/dist/composables/useChemicalFormula.d.ts +21 -0
- package/dist/composables/useConcentrationUnits.d.ts +29 -0
- package/dist/composables/useDoseCalculator.d.ts +58 -0
- package/dist/composables/useExperimentData.d.ts +18 -0
- package/dist/composables/useExperimentSave.d.ts +36 -0
- package/dist/composables/useExperimentSelector.d.ts +30 -0
- package/dist/composables/useForm.d.ts +92 -0
- package/dist/composables/useFormBuilder.d.ts +24 -0
- package/dist/composables/usePasskey.d.ts +10 -0
- package/dist/composables/usePlatformContext.d.ts +131 -0
- package/dist/composables/usePluginApi.d.ts +29 -0
- package/dist/composables/usePluginConfig.d.ts +13 -0
- package/dist/composables/useProtocolTemplates.d.ts +44 -0
- package/dist/composables/useRackEditor.d.ts +31 -0
- package/dist/composables/useReagentSeries.d.ts +23 -0
- package/dist/composables/useScheduleDrag.d.ts +78 -0
- package/dist/composables/useSequenceUtils.d.ts +14 -0
- package/dist/composables/useTheme.d.ts +8 -0
- package/dist/composables/useTimeUtils.d.ts +29 -0
- package/dist/composables/useToast.d.ts +22 -0
- package/dist/composables/useWellPlateEditor.d.ts +33 -0
- package/dist/composables-D0QfFzq1.js +805 -0
- package/dist/composables-D0QfFzq1.js.map +1 -0
- package/dist/histoire.setup.d.ts +1 -0
- package/dist/index.d.ts +6 -0
- package/dist/index.js +7 -0
- package/dist/install.d.ts +16 -0
- package/dist/install.js +23 -0
- package/dist/install.js.map +1 -0
- package/dist/stores/auth.d.ts +146 -0
- package/dist/stores/index.d.ts +2 -0
- package/dist/stores/index.js +2 -0
- package/dist/stores/settings.d.ts +75 -0
- package/dist/styles.css +29728 -0
- package/dist/tailwind.preset.d.ts +58 -0
- package/dist/tailwind.preset.js +66 -0
- package/dist/tailwind.preset.js.map +1 -0
- package/dist/types/auth.d.ts +42 -0
- package/dist/types/auto-group.d.ts +34 -0
- package/dist/types/components.d.ts +528 -0
- package/dist/types/form-builder.d.ts +167 -0
- package/dist/types/index.d.ts +5 -0
- package/dist/types/index.js +0 -0
- package/dist/types/platform.d.ts +75 -0
- package/dist/useScheduleDrag-DAJueTbK.js +7181 -0
- package/dist/useScheduleDrag-DAJueTbK.js.map +1 -0
- package/dist/utils/color.d.ts +24 -0
- package/package.json +114 -0
- package/src/__stories__/experiment-helpers.ts +83 -0
- package/src/__tests__/components/AppLayout.test.ts +163 -0
- package/src/__tests__/components/AppSidebar.test.ts +292 -0
- package/src/__tests__/components/AppTopBar.test.ts +683 -0
- package/src/__tests__/components/BaseInput.test.ts +99 -0
- package/src/__tests__/components/BasePill.test.ts +291 -0
- package/src/__tests__/components/Calendar.test.ts +566 -0
- package/src/__tests__/components/CollapsibleCard.test.ts +524 -0
- package/src/__tests__/components/DataFrame.test.ts +767 -0
- package/src/__tests__/components/DropdownButton.test.ts +471 -0
- package/src/__tests__/composables/formBuilderRegistry.test.ts +187 -0
- package/src/__tests__/composables/useAppExperiment.test.ts +560 -0
- package/src/__tests__/composables/useAuth.test.ts +188 -0
- package/src/__tests__/composables/useAutoGroup.test.ts +860 -0
- package/src/__tests__/composables/useExperimentData.test.ts +127 -0
- package/src/__tests__/composables/useExperimentSave.test.ts +347 -0
- package/src/__tests__/composables/useForm.test.ts +205 -0
- package/src/__tests__/composables/useFormBuilder.test.ts +917 -0
- package/src/__tests__/composables/usePlatformContext.test.ts +116 -0
- package/src/__tests__/composables/usePluginApi.test.ts +81 -0
- package/src/__tests__/composables/usePluginConfig.test.ts +176 -0
- package/src/__tests__/utils/color.test.ts +96 -0
- package/src/components/AlertBox.story.vue +204 -0
- package/src/components/AlertBox.vue +88 -0
- package/src/components/AppAvatarMenu.story.vue +155 -0
- package/src/components/AppAvatarMenu.vue +184 -0
- package/src/components/AppContainer.story.vue +104 -0
- package/src/components/AppContainer.vue +34 -0
- package/src/components/AppLayout.story.vue +292 -0
- package/src/components/AppLayout.vue +75 -0
- package/src/components/AppPageSelector.vue +159 -0
- package/src/components/AppPillNav.vue +66 -0
- package/src/components/AppPluginSwitcher.vue +241 -0
- package/src/components/AppSidebar.story.vue +309 -0
- package/src/components/AppSidebar.vue +119 -0
- package/src/components/AppTopBar.story.vue +304 -0
- package/src/components/AppTopBar.vue +661 -0
- package/src/components/AuditTrail.story.vue +163 -0
- package/src/components/AuditTrail.vue +151 -0
- package/src/components/AutoGroupModal.story.vue +273 -0
- package/src/components/AutoGroupModal.vue +566 -0
- package/src/components/Avatar.story.vue +115 -0
- package/src/components/Avatar.vue +79 -0
- package/src/components/BaseButton.story.vue +96 -0
- package/src/components/BaseButton.vue +73 -0
- package/src/components/BaseCheckbox.story.vue +73 -0
- package/src/components/BaseCheckbox.vue +69 -0
- package/src/components/BaseInput.story.vue +98 -0
- package/src/components/BaseInput.vue +74 -0
- package/src/components/BaseModal.story.vue +237 -0
- package/src/components/BaseModal.vue +182 -0
- package/src/components/BasePill.story.vue +142 -0
- package/src/components/BasePill.vue +89 -0
- package/src/components/BaseRadioGroup.story.vue +145 -0
- package/src/components/BaseRadioGroup.vue +124 -0
- package/src/components/BaseSelect.story.vue +120 -0
- package/src/components/BaseSelect.vue +71 -0
- package/src/components/BaseSlider.story.vue +122 -0
- package/src/components/BaseSlider.vue +126 -0
- package/src/components/BaseTabs.story.vue +127 -0
- package/src/components/BaseTabs.vue +59 -0
- package/src/components/BaseTextarea.story.vue +91 -0
- package/src/components/BaseTextarea.vue +62 -0
- package/src/components/BaseToggle.story.vue +81 -0
- package/src/components/BaseToggle.vue +76 -0
- package/src/components/BatchProgressList.story.vue +92 -0
- package/src/components/BatchProgressList.vue +184 -0
- package/src/components/Breadcrumb.story.vue +106 -0
- package/src/components/Breadcrumb.vue +75 -0
- package/src/components/Calendar.story.vue +106 -0
- package/src/components/Calendar.vue +363 -0
- package/src/components/ChartContainer.story.vue +113 -0
- package/src/components/ChartContainer.vue +64 -0
- package/src/components/ChemicalFormula.story.vue +102 -0
- package/src/components/ChemicalFormula.vue +39 -0
- package/src/components/CollapsibleCard.story.vue +135 -0
- package/src/components/CollapsibleCard.vue +167 -0
- package/src/components/ColorSlider.story.vue +120 -0
- package/src/components/ColorSlider.vue +164 -0
- package/src/components/ConcentrationInput.story.vue +77 -0
- package/src/components/ConcentrationInput.vue +185 -0
- package/src/components/ConfirmDialog.story.vue +248 -0
- package/src/components/ConfirmDialog.vue +93 -0
- package/src/components/DataFrame.story.vue +148 -0
- package/src/components/DataFrame.vue +419 -0
- package/src/components/DatePicker.story.vue +119 -0
- package/src/components/DatePicker.vue +330 -0
- package/src/components/DateTimePicker.story.vue +112 -0
- package/src/components/DateTimePicker.vue +392 -0
- package/src/components/Divider.story.vue +80 -0
- package/src/components/Divider.vue +49 -0
- package/src/components/DoseCalculator.story.vue +68 -0
- package/src/components/DoseCalculator.vue +476 -0
- package/src/components/DropdownButton.story.vue +102 -0
- package/src/components/DropdownButton.vue +181 -0
- package/src/components/EmptyState.story.vue +135 -0
- package/src/components/EmptyState.vue +69 -0
- package/src/components/ExperimentCodeBadge.story.vue +77 -0
- package/src/components/ExperimentCodeBadge.vue +64 -0
- package/src/components/ExperimentDataViewer.story.vue +174 -0
- package/src/components/ExperimentDataViewer.vue +288 -0
- package/src/components/ExperimentPopover.story.vue +384 -0
- package/src/components/ExperimentPopover.vue +241 -0
- package/src/components/ExperimentSelectorModal.story.vue +391 -0
- package/src/components/ExperimentSelectorModal.vue +387 -0
- package/src/components/ExperimentTimeline.story.vue +161 -0
- package/src/components/ExperimentTimeline.vue +382 -0
- package/src/components/FileUploader.story.vue +107 -0
- package/src/components/FileUploader.vue +386 -0
- package/src/components/FitPanel.story.vue +125 -0
- package/src/components/FitPanel.vue +120 -0
- package/src/components/FormActions.vue +92 -0
- package/src/components/FormBuilder.vue +214 -0
- package/src/components/FormField.story.vue +132 -0
- package/src/components/FormField.vue +59 -0
- package/src/components/FormFieldRenderer.vue +58 -0
- package/src/components/FormSection.vue +90 -0
- package/src/components/FormulaInput.story.vue +96 -0
- package/src/components/FormulaInput.vue +125 -0
- package/src/components/GroupAssigner.story.vue +83 -0
- package/src/components/GroupAssigner.vue +284 -0
- package/src/components/GroupingModal.story.vue +52 -0
- package/src/components/GroupingModal.vue +422 -0
- package/src/components/IconButton.story.vue +135 -0
- package/src/components/IconButton.vue +73 -0
- package/src/components/LoadingSpinner.story.vue +70 -0
- package/src/components/LoadingSpinner.vue +50 -0
- package/src/components/MoleculeInput.story.vue +66 -0
- package/src/components/MoleculeInput.vue +426 -0
- package/src/components/MultiSelect.story.vue +132 -0
- package/src/components/MultiSelect.vue +118 -0
- package/src/components/NumberInput.story.vue +122 -0
- package/src/components/NumberInput.vue +160 -0
- package/src/components/PlateMapEditor.story.vue +92 -0
- package/src/components/PlateMapEditor.vue +513 -0
- package/src/components/ProgressBar.story.vue +148 -0
- package/src/components/ProgressBar.vue +114 -0
- package/src/components/ProtocolStepEditor.story.vue +69 -0
- package/src/components/ProtocolStepEditor.vue +522 -0
- package/src/components/RackEditor.story.vue +100 -0
- package/src/components/RackEditor.vue +371 -0
- package/src/components/ReagentEditor.story.vue +153 -0
- package/src/components/ReagentEditor.vue +418 -0
- package/src/components/ReagentList.story.vue +137 -0
- package/src/components/ReagentList.vue +463 -0
- package/src/components/ResourceCard.story.vue +150 -0
- package/src/components/ResourceCard.vue +161 -0
- package/src/components/SampleHierarchyTree.story.vue +161 -0
- package/src/components/SampleHierarchyTree.vue +256 -0
- package/src/components/SampleLegend.story.vue +91 -0
- package/src/components/SampleLegend.vue +119 -0
- package/src/components/SampleSelector.story.vue +111 -0
- package/src/components/SampleSelector.vue +1033 -0
- package/src/components/ScheduleCalendar.story.vue +195 -0
- package/src/components/ScheduleCalendar.vue +569 -0
- package/src/components/ScientificNumber.story.vue +127 -0
- package/src/components/ScientificNumber.vue +197 -0
- package/src/components/SegmentedControl.story.vue +132 -0
- package/src/components/SegmentedControl.vue +79 -0
- package/src/components/SequenceInput.story.vue +119 -0
- package/src/components/SequenceInput.vue +209 -0
- package/src/components/SettingsButton.story.vue +58 -0
- package/src/components/SettingsButton.vue +76 -0
- package/src/components/SettingsModal.story.vue +145 -0
- package/src/components/SettingsModal.vue +146 -0
- package/src/components/Skeleton.story.vue +141 -0
- package/src/components/Skeleton.vue +74 -0
- package/src/components/StatusIndicator.story.vue +99 -0
- package/src/components/StatusIndicator.vue +40 -0
- package/src/components/StepWizard.story.vue +155 -0
- package/src/components/StepWizard.vue +223 -0
- package/src/components/TagsInput.story.vue +155 -0
- package/src/components/TagsInput.vue +265 -0
- package/src/components/ThemeToggle.story.vue +36 -0
- package/src/components/ThemeToggle.vue +54 -0
- package/src/components/TimePicker.story.vue +96 -0
- package/src/components/TimePicker.vue +273 -0
- package/src/components/TimeRangeInput.story.vue +104 -0
- package/src/components/TimeRangeInput.vue +122 -0
- package/src/components/ToastNotification.story.vue +157 -0
- package/src/components/ToastNotification.vue +62 -0
- package/src/components/Tooltip.story.vue +138 -0
- package/src/components/Tooltip.vue +119 -0
- package/src/components/UnitInput.story.vue +194 -0
- package/src/components/UnitInput.vue +213 -0
- package/src/components/WellEditPopup.vue +234 -0
- package/src/components/WellPlate.story.vue +282 -0
- package/src/components/WellPlate.vue +830 -0
- package/src/components/index.ts +118 -0
- package/src/composables/experiment-utils.ts +57 -0
- package/src/composables/formBuilderRegistry.ts +79 -0
- package/src/composables/index.ts +140 -0
- package/src/composables/useApi.ts +167 -0
- package/src/composables/useAppExperiment.ts +159 -0
- package/src/composables/useAsync.ts +323 -0
- package/src/composables/useAuth.ts +445 -0
- package/src/composables/useAutoGroup.ts +641 -0
- package/src/composables/useChemicalFormula.ts +275 -0
- package/src/composables/useConcentrationUnits.ts +246 -0
- package/src/composables/useDoseCalculator.ts +370 -0
- package/src/composables/useExperimentData.ts +86 -0
- package/src/composables/useExperimentSave.ts +192 -0
- package/src/composables/useExperimentSelector.ts +292 -0
- package/src/composables/useForm.ts +416 -0
- package/src/composables/useFormBuilder.ts +383 -0
- package/src/composables/usePasskey.ts +216 -0
- package/src/composables/usePlatformContext.ts +299 -0
- package/src/composables/usePluginApi.ts +39 -0
- package/src/composables/usePluginConfig.ts +93 -0
- package/src/composables/useProtocolTemplates.ts +518 -0
- package/src/composables/useRackEditor.ts +222 -0
- package/src/composables/useReagentSeries.ts +91 -0
- package/src/composables/useScheduleDrag.ts +245 -0
- package/src/composables/useSequenceUtils.ts +105 -0
- package/src/composables/useTheme.ts +58 -0
- package/src/composables/useTimeUtils.ts +131 -0
- package/src/composables/useToast.ts +40 -0
- package/src/composables/useWellPlateEditor.ts +421 -0
- package/src/histoire.setup.ts +17 -0
- package/src/index.ts +367 -0
- package/src/install.ts +32 -0
- package/src/stores/auth.ts +152 -0
- package/src/stores/index.ts +2 -0
- package/src/stores/settings.ts +218 -0
- package/src/styles/components/alert-box.css +150 -0
- package/src/styles/components/app-avatar-menu.css +155 -0
- package/src/styles/components/app-container.css +33 -0
- package/src/styles/components/app-layout.css +98 -0
- package/src/styles/components/app-page-selector.css +191 -0
- package/src/styles/components/app-pill-nav.css +57 -0
- package/src/styles/components/app-plugin-switcher.css +209 -0
- package/src/styles/components/app-sidebar.css +145 -0
- package/src/styles/components/app-top-bar.css +492 -0
- package/src/styles/components/audit-trail.css +143 -0
- package/src/styles/components/auto-group-modal.css +644 -0
- package/src/styles/components/avatar.css +73 -0
- package/src/styles/components/batch-progress-list.css +196 -0
- package/src/styles/components/breadcrumb.css +64 -0
- package/src/styles/components/button.css +188 -0
- package/src/styles/components/calendar.css +192 -0
- package/src/styles/components/chart-container.css +69 -0
- package/src/styles/components/checkbox.css +123 -0
- package/src/styles/components/chemical-formula.css +46 -0
- package/src/styles/components/collapsible-card.css +253 -0
- package/src/styles/components/color-slider.css +110 -0
- package/src/styles/components/concentration-input.css +156 -0
- package/src/styles/components/confirm-dialog.css +183 -0
- package/src/styles/components/dataframe.css +382 -0
- package/src/styles/components/date-picker.css +243 -0
- package/src/styles/components/datetime-picker.css +229 -0
- package/src/styles/components/divider.css +63 -0
- package/src/styles/components/dose-calculator.css +301 -0
- package/src/styles/components/dropdown-button.css +280 -0
- package/src/styles/components/empty-state.css +151 -0
- package/src/styles/components/experiment-code-badge.css +33 -0
- package/src/styles/components/experiment-data-viewer.css +138 -0
- package/src/styles/components/experiment-popover.css +562 -0
- package/src/styles/components/experiment-selector-modal.css +285 -0
- package/src/styles/components/experiment-timeline.css +529 -0
- package/src/styles/components/file-uploader.css +310 -0
- package/src/styles/components/fit-panel.css +67 -0
- package/src/styles/components/form-builder.css +69 -0
- package/src/styles/components/form-field.css +48 -0
- package/src/styles/components/formula-input.css +103 -0
- package/src/styles/components/group-assigner.css +200 -0
- package/src/styles/components/grouping-modal.css +323 -0
- package/src/styles/components/icon-button.css +192 -0
- package/src/styles/components/input.css +66 -0
- package/src/styles/components/loading-spinner.css +67 -0
- package/src/styles/components/modal.css +350 -0
- package/src/styles/components/molecule-input.css +186 -0
- package/src/styles/components/multi-select.css +131 -0
- package/src/styles/components/number-input.css +199 -0
- package/src/styles/components/pill.css +188 -0
- package/src/styles/components/plate-map-editor.css +464 -0
- package/src/styles/components/progress-bar.css +133 -0
- package/src/styles/components/protocol-step-editor.css +449 -0
- package/src/styles/components/rack-editor.css +265 -0
- package/src/styles/components/radio-group.css +240 -0
- package/src/styles/components/reagent-editor.css +510 -0
- package/src/styles/components/reagent-list.css +407 -0
- package/src/styles/components/resource-card.css +360 -0
- package/src/styles/components/sample-hierarchy-tree.css +314 -0
- package/src/styles/components/sample-legend.css +201 -0
- package/src/styles/components/sample-selector.css +751 -0
- package/src/styles/components/schedule-calendar.css +478 -0
- package/src/styles/components/scientific-number.css +63 -0
- package/src/styles/components/segmented-control.css +197 -0
- package/src/styles/components/select.css +77 -0
- package/src/styles/components/sequence-input.css +184 -0
- package/src/styles/components/settings-button.css +94 -0
- package/src/styles/components/settings-modal.css +95 -0
- package/src/styles/components/skeleton.css +49 -0
- package/src/styles/components/slider.css +74 -0
- package/src/styles/components/status-indicator.css +66 -0
- package/src/styles/components/step-wizard.css +192 -0
- package/src/styles/components/tabs.css +95 -0
- package/src/styles/components/tags-input.css +195 -0
- package/src/styles/components/textarea.css +82 -0
- package/src/styles/components/theme-toggle.css +69 -0
- package/src/styles/components/time-picker.css +171 -0
- package/src/styles/components/time-range-input.css +42 -0
- package/src/styles/components/toast.css +91 -0
- package/src/styles/components/toggle.css +146 -0
- package/src/styles/components/tooltip.css +91 -0
- package/src/styles/components/unit-input.css +123 -0
- package/src/styles/components/well-edit-popup.css +252 -0
- package/src/styles/components/well-plate.css +307 -0
- package/src/styles/index.css +87 -0
- package/src/styles/variables.css +1117 -0
- package/src/tailwind.preset.ts +61 -0
- package/src/types/auth.ts +55 -0
- package/src/types/auto-group.ts +40 -0
- package/src/types/components.ts +710 -0
- package/src/types/form-builder.ts +197 -0
- package/src/types/index.ts +207 -0
- package/src/types/platform.ts +116 -0
- package/src/utils/color.ts +96 -0
|
@@ -0,0 +1,163 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import AuditTrail from './AuditTrail.vue'
|
|
3
|
+
|
|
4
|
+
const now = new Date()
|
|
5
|
+
|
|
6
|
+
function minutesAgo(mins: number): Date {
|
|
7
|
+
return new Date(now.getTime() - mins * 60 * 1000)
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
function hoursAgo(hrs: number): Date {
|
|
11
|
+
return new Date(now.getTime() - hrs * 60 * 60 * 1000)
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
function daysAgo(days: number): Date {
|
|
15
|
+
return new Date(now.getTime() - days * 24 * 60 * 60 * 1000)
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
const mockEntries = [
|
|
19
|
+
{
|
|
20
|
+
id: 'e1',
|
|
21
|
+
type: 'create' as const,
|
|
22
|
+
action: 'Created experiment "Cisplatin Dose Response"',
|
|
23
|
+
detail: 'Initial setup with 96-well plate format, 8 concentration points.',
|
|
24
|
+
user: 'Elena Morscher',
|
|
25
|
+
timestamp: minutesAgo(5),
|
|
26
|
+
metadata: { 'Plate format': '96-well', 'Compounds': '1' },
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
id: 'e2',
|
|
30
|
+
type: 'update' as const,
|
|
31
|
+
action: 'Updated sample assignments',
|
|
32
|
+
detail: 'Assigned HeLa cells to wells A1-A12 and MCF-7 to wells B1-B12.',
|
|
33
|
+
user: 'Elena Morscher',
|
|
34
|
+
timestamp: minutesAgo(45),
|
|
35
|
+
},
|
|
36
|
+
{
|
|
37
|
+
id: 'e3',
|
|
38
|
+
type: 'update' as const,
|
|
39
|
+
action: 'Modified protocol step "Incubation"',
|
|
40
|
+
detail: 'Changed incubation time from 24h to 48h.',
|
|
41
|
+
user: 'Thomas Weber',
|
|
42
|
+
timestamp: hoursAgo(2),
|
|
43
|
+
metadata: { 'Previous': '24h', 'New': '48h' },
|
|
44
|
+
},
|
|
45
|
+
{
|
|
46
|
+
id: 'e4',
|
|
47
|
+
type: 'system' as const,
|
|
48
|
+
action: 'Plate reader measurement completed',
|
|
49
|
+
detail: 'Luminescence readout finished for plate 1. 96/96 wells measured successfully.',
|
|
50
|
+
user: undefined,
|
|
51
|
+
timestamp: hoursAgo(6),
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
id: 'e5',
|
|
55
|
+
type: 'delete' as const,
|
|
56
|
+
action: 'Removed blank wells from analysis',
|
|
57
|
+
detail: 'Wells H1-H12 excluded from dose-response curve fitting.',
|
|
58
|
+
user: 'Elena Morscher',
|
|
59
|
+
timestamp: daysAgo(1),
|
|
60
|
+
},
|
|
61
|
+
{
|
|
62
|
+
id: 'e6',
|
|
63
|
+
type: 'create' as const,
|
|
64
|
+
action: 'Generated analysis report',
|
|
65
|
+
detail: 'IC50 curve fitting completed. Report exported as PDF.',
|
|
66
|
+
user: 'Thomas Weber',
|
|
67
|
+
timestamp: daysAgo(2),
|
|
68
|
+
metadata: { 'IC50': '3.2 uM', 'R-squared': '0.98' },
|
|
69
|
+
},
|
|
70
|
+
{
|
|
71
|
+
id: 'e7',
|
|
72
|
+
type: 'system' as const,
|
|
73
|
+
action: 'Experiment status changed to "Completed"',
|
|
74
|
+
user: undefined,
|
|
75
|
+
timestamp: daysAgo(3),
|
|
76
|
+
},
|
|
77
|
+
]
|
|
78
|
+
|
|
79
|
+
function initState() {
|
|
80
|
+
return {
|
|
81
|
+
entries: mockEntries,
|
|
82
|
+
showFilters: false,
|
|
83
|
+
emptyMessage: 'No activity yet',
|
|
84
|
+
order: 'newest' as const,
|
|
85
|
+
size: 'md' as const,
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
</script>
|
|
89
|
+
|
|
90
|
+
<template>
|
|
91
|
+
<Story title="Workflow/AuditTrail">
|
|
92
|
+
<Variant title="Playground" :init-state="initState">
|
|
93
|
+
<template #default="{ state }">
|
|
94
|
+
<div style="padding: 2rem; max-width: 600px;">
|
|
95
|
+
<AuditTrail
|
|
96
|
+
:entries="state.entries"
|
|
97
|
+
:show-filters="state.showFilters"
|
|
98
|
+
:empty-message="state.emptyMessage"
|
|
99
|
+
:order="state.order"
|
|
100
|
+
:size="state.size"
|
|
101
|
+
/>
|
|
102
|
+
</div>
|
|
103
|
+
</template>
|
|
104
|
+
<template #controls="{ state }">
|
|
105
|
+
<HstCheckbox v-model="state.showFilters" title="Show Filters" />
|
|
106
|
+
<HstText v-model="state.emptyMessage" title="Empty Message" />
|
|
107
|
+
<HstSelect
|
|
108
|
+
v-model="state.order"
|
|
109
|
+
title="Order"
|
|
110
|
+
:options="[
|
|
111
|
+
{ value: 'newest', label: 'Newest First' },
|
|
112
|
+
{ value: 'oldest', label: 'Oldest First' },
|
|
113
|
+
]"
|
|
114
|
+
/>
|
|
115
|
+
<HstSelect
|
|
116
|
+
v-model="state.size"
|
|
117
|
+
title="Size"
|
|
118
|
+
:options="[
|
|
119
|
+
{ value: 'sm', label: 'Small' },
|
|
120
|
+
{ value: 'md', label: 'Medium' },
|
|
121
|
+
{ value: 'lg', label: 'Large' },
|
|
122
|
+
]"
|
|
123
|
+
/>
|
|
124
|
+
</template>
|
|
125
|
+
</Variant>
|
|
126
|
+
|
|
127
|
+
<Variant title="With Filters">
|
|
128
|
+
<div style="padding: 2rem; max-width: 600px;">
|
|
129
|
+
<AuditTrail
|
|
130
|
+
:entries="mockEntries"
|
|
131
|
+
show-filters
|
|
132
|
+
/>
|
|
133
|
+
</div>
|
|
134
|
+
</Variant>
|
|
135
|
+
|
|
136
|
+
<Variant title="With Max Height">
|
|
137
|
+
<div style="padding: 2rem; max-width: 600px;">
|
|
138
|
+
<AuditTrail
|
|
139
|
+
:entries="mockEntries"
|
|
140
|
+
max-height="300px"
|
|
141
|
+
/>
|
|
142
|
+
</div>
|
|
143
|
+
</Variant>
|
|
144
|
+
|
|
145
|
+
<Variant title="Oldest First">
|
|
146
|
+
<div style="padding: 2rem; max-width: 600px;">
|
|
147
|
+
<AuditTrail
|
|
148
|
+
:entries="mockEntries"
|
|
149
|
+
order="oldest"
|
|
150
|
+
/>
|
|
151
|
+
</div>
|
|
152
|
+
</Variant>
|
|
153
|
+
|
|
154
|
+
<Variant title="Empty">
|
|
155
|
+
<div style="padding: 2rem; max-width: 600px;">
|
|
156
|
+
<AuditTrail
|
|
157
|
+
:entries="[]"
|
|
158
|
+
empty-message="No audit events recorded"
|
|
159
|
+
/>
|
|
160
|
+
</div>
|
|
161
|
+
</Variant>
|
|
162
|
+
</Story>
|
|
163
|
+
</template>
|
|
@@ -0,0 +1,151 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
/** Filterable, sortable timeline of audit entries for tracking experiment or resource history. */
|
|
3
|
+
import { computed, ref } from 'vue'
|
|
4
|
+
import type { AuditEntryType, AuditEntry } from '../types'
|
|
5
|
+
|
|
6
|
+
interface Props {
|
|
7
|
+
entries: AuditEntry[]
|
|
8
|
+
maxHeight?: string
|
|
9
|
+
showFilters?: boolean
|
|
10
|
+
emptyMessage?: string
|
|
11
|
+
order?: 'newest' | 'oldest'
|
|
12
|
+
size?: 'sm' | 'md' | 'lg'
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
const props = withDefaults(defineProps<Props>(), {
|
|
16
|
+
showFilters: false,
|
|
17
|
+
emptyMessage: 'No activity yet',
|
|
18
|
+
order: 'newest',
|
|
19
|
+
size: 'md',
|
|
20
|
+
})
|
|
21
|
+
|
|
22
|
+
const emit = defineEmits<{
|
|
23
|
+
'entry-click': [entry: AuditEntry]
|
|
24
|
+
}>()
|
|
25
|
+
|
|
26
|
+
const filterType = ref<AuditEntryType | ''>('')
|
|
27
|
+
const filterUser = ref('')
|
|
28
|
+
|
|
29
|
+
const uniqueTypes = computed(() => {
|
|
30
|
+
const types = new Set(props.entries.map(e => e.type))
|
|
31
|
+
return Array.from(types)
|
|
32
|
+
})
|
|
33
|
+
|
|
34
|
+
const uniqueUsers = computed(() => {
|
|
35
|
+
const users = new Set(props.entries.filter(e => e.user).map(e => e.user!))
|
|
36
|
+
return Array.from(users)
|
|
37
|
+
})
|
|
38
|
+
|
|
39
|
+
const filteredEntries = computed(() => {
|
|
40
|
+
let result = props.entries
|
|
41
|
+
if (filterType.value) {
|
|
42
|
+
result = result.filter(e => e.type === filterType.value)
|
|
43
|
+
}
|
|
44
|
+
if (filterUser.value) {
|
|
45
|
+
result = result.filter(e => e.user === filterUser.value)
|
|
46
|
+
}
|
|
47
|
+
return result
|
|
48
|
+
})
|
|
49
|
+
|
|
50
|
+
const sortedEntries = computed(() => {
|
|
51
|
+
const entries = [...filteredEntries.value]
|
|
52
|
+
entries.sort((a, b) => {
|
|
53
|
+
const timeA = new Date(a.timestamp).getTime()
|
|
54
|
+
const timeB = new Date(b.timestamp).getTime()
|
|
55
|
+
return props.order === 'newest' ? timeB - timeA : timeA - timeB
|
|
56
|
+
})
|
|
57
|
+
return entries
|
|
58
|
+
})
|
|
59
|
+
|
|
60
|
+
function getInitials(name: string): string {
|
|
61
|
+
const words = name.trim().split(/\s+/)
|
|
62
|
+
if (words.length >= 2) {
|
|
63
|
+
return (words[0][0] + words[1][0]).toUpperCase()
|
|
64
|
+
}
|
|
65
|
+
return (words[0]?.[0] ?? '').toUpperCase()
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
const rtf = new Intl.RelativeTimeFormat('en', { numeric: 'auto' })
|
|
69
|
+
|
|
70
|
+
function formatTimestamp(timestamp: Date | string): string {
|
|
71
|
+
const date = timestamp instanceof Date ? timestamp : new Date(timestamp)
|
|
72
|
+
const now = Date.now()
|
|
73
|
+
const diffMs = date.getTime() - now
|
|
74
|
+
const diffSec = Math.round(diffMs / 1000)
|
|
75
|
+
const diffMin = Math.round(diffSec / 60)
|
|
76
|
+
const diffHr = Math.round(diffMin / 60)
|
|
77
|
+
const diffDay = Math.round(diffHr / 24)
|
|
78
|
+
const diffWeek = Math.round(diffDay / 7)
|
|
79
|
+
|
|
80
|
+
if (Math.abs(diffSec) < 60) return rtf.format(diffSec, 'second')
|
|
81
|
+
if (Math.abs(diffMin) < 60) return rtf.format(diffMin, 'minute')
|
|
82
|
+
if (Math.abs(diffHr) < 24) return rtf.format(diffHr, 'hour')
|
|
83
|
+
if (Math.abs(diffDay) < 7) return rtf.format(diffDay, 'day')
|
|
84
|
+
if (Math.abs(diffWeek) < 5) return rtf.format(diffWeek, 'week')
|
|
85
|
+
return date.toLocaleDateString()
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
function handleEntryClick(entry: AuditEntry) {
|
|
89
|
+
emit('entry-click', entry)
|
|
90
|
+
}
|
|
91
|
+
</script>
|
|
92
|
+
|
|
93
|
+
<template>
|
|
94
|
+
<div :class="['mld-audit-trail', `mld-audit-trail--${size}`]">
|
|
95
|
+
<div v-if="showFilters" class="mld-audit-trail__filters">
|
|
96
|
+
<select v-model="filterType" class="mld-audit-trail__filter-select">
|
|
97
|
+
<option value="">All types</option>
|
|
98
|
+
<option v-for="t in uniqueTypes" :key="t" :value="t">{{ t }}</option>
|
|
99
|
+
</select>
|
|
100
|
+
<select v-model="filterUser" class="mld-audit-trail__filter-select">
|
|
101
|
+
<option value="">All users</option>
|
|
102
|
+
<option v-for="u in uniqueUsers" :key="u" :value="u">{{ u }}</option>
|
|
103
|
+
</select>
|
|
104
|
+
</div>
|
|
105
|
+
|
|
106
|
+
<div
|
|
107
|
+
v-if="sortedEntries.length"
|
|
108
|
+
class="mld-audit-trail__list"
|
|
109
|
+
:style="maxHeight ? { maxHeight, overflowY: 'auto' } : {}"
|
|
110
|
+
>
|
|
111
|
+
<div class="mld-audit-trail__line" />
|
|
112
|
+
<div
|
|
113
|
+
v-for="entry in sortedEntries"
|
|
114
|
+
:key="entry.id"
|
|
115
|
+
:class="['mld-audit-trail__entry', `mld-audit-trail__entry--${entry.type}`]"
|
|
116
|
+
@click="handleEntryClick(entry)"
|
|
117
|
+
>
|
|
118
|
+
<slot name="entry" :entry="entry">
|
|
119
|
+
<div class="mld-audit-trail__dot" />
|
|
120
|
+
<div class="mld-audit-trail__content">
|
|
121
|
+
<div class="mld-audit-trail__header">
|
|
122
|
+
<div v-if="entry.user" class="mld-audit-trail__avatar">{{ getInitials(entry.user) }}</div>
|
|
123
|
+
<span v-if="entry.user" class="mld-audit-trail__user">{{ entry.user }}</span>
|
|
124
|
+
<span class="mld-audit-trail__timestamp">{{ formatTimestamp(entry.timestamp) }}</span>
|
|
125
|
+
</div>
|
|
126
|
+
<div class="mld-audit-trail__action">{{ entry.action }}</div>
|
|
127
|
+
<div v-if="entry.detail" class="mld-audit-trail__detail">{{ entry.detail }}</div>
|
|
128
|
+
<div v-if="entry.metadata && Object.keys(entry.metadata).length" class="mld-audit-trail__metadata">
|
|
129
|
+
<span
|
|
130
|
+
v-for="(value, key) in entry.metadata"
|
|
131
|
+
:key="String(key)"
|
|
132
|
+
class="mld-audit-trail__metadata-item"
|
|
133
|
+
>
|
|
134
|
+
<span class="mld-audit-trail__metadata-key">{{ key }}:</span>
|
|
135
|
+
{{ value }}
|
|
136
|
+
</span>
|
|
137
|
+
</div>
|
|
138
|
+
</div>
|
|
139
|
+
</slot>
|
|
140
|
+
</div>
|
|
141
|
+
</div>
|
|
142
|
+
|
|
143
|
+
<div v-if="!sortedEntries.length" class="mld-audit-trail__empty">
|
|
144
|
+
<slot name="empty">{{ emptyMessage }}</slot>
|
|
145
|
+
</div>
|
|
146
|
+
</div>
|
|
147
|
+
</template>
|
|
148
|
+
|
|
149
|
+
<style>
|
|
150
|
+
@import '../styles/components/audit-trail.css';
|
|
151
|
+
</style>
|
|
@@ -0,0 +1,273 @@
|
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import { ref } from 'vue'
|
|
3
|
+
import AutoGroupModal from './AutoGroupModal.vue'
|
|
4
|
+
import type { AutoGroupResult } from '../types/auto-group'
|
|
5
|
+
|
|
6
|
+
// Realistic proteomics-style samples with consistent structure
|
|
7
|
+
const proteomicsSamples = [
|
|
8
|
+
'Ctrl_Liver_D1_Rep1', 'Ctrl_Liver_D1_Rep2', 'Ctrl_Liver_D1_Rep3',
|
|
9
|
+
'Ctrl_Brain_D1_Rep1', 'Ctrl_Brain_D1_Rep2', 'Ctrl_Brain_D1_Rep3',
|
|
10
|
+
'Treat_Liver_D3_Rep1', 'Treat_Liver_D3_Rep2', 'Treat_Liver_D3_Rep3',
|
|
11
|
+
'Treat_Brain_D3_Rep1', 'Treat_Brain_D3_Rep2', 'Treat_Brain_D3_Rep3',
|
|
12
|
+
]
|
|
13
|
+
|
|
14
|
+
// Samples with outliers (QC pools, blanks)
|
|
15
|
+
const withOutliersSamples = [
|
|
16
|
+
'Ctrl_Liver_D1_Rep1', 'Ctrl_Liver_D1_Rep2',
|
|
17
|
+
'Treat_Liver_D3_Rep1', 'Treat_Liver_D3_Rep2',
|
|
18
|
+
'QC_Pool', 'Blank', 'ISTD_Mix',
|
|
19
|
+
'Ctrl_Brain_D1_Rep1', 'Ctrl_Brain_D1_Rep2',
|
|
20
|
+
]
|
|
21
|
+
|
|
22
|
+
// Real-world mixed dataset: 11-field experimental + 6-field QC + 4-field test
|
|
23
|
+
// This exercises the dominantFieldCount outlier fix
|
|
24
|
+
const mixedFieldCountSamples = [
|
|
25
|
+
// Experimental (11 fields each)
|
|
26
|
+
'LT_13102025_212_WT_Glu_3_20_S_091123_T1_33',
|
|
27
|
+
'LT_13102025_213_WT_Glu_3_20_S_091123_T1_34',
|
|
28
|
+
'LT_13102025_214_KI_Glu_3_20_S_091123_T1_35',
|
|
29
|
+
'LT_13102025_215_KI_Glu_6_40_L_091123_T1_36',
|
|
30
|
+
'LT_13102025_216_WT_Glu_6_40_L_091123_T1_37',
|
|
31
|
+
'LT_13102025_217_WT_Glu_6_40_L_091123_T2_38',
|
|
32
|
+
'LT_13102025_218_KI_Glu_3_20_S_091123_T2_39',
|
|
33
|
+
'LT_13102025_219_KI_Glu_6_40_L_091123_T2_40',
|
|
34
|
+
'LT_13102025_220_WT_Glu_3_20_S_091123_T2_41',
|
|
35
|
+
'LT_13102025_221_WT_Glu_6_40_L_091123_T2_42',
|
|
36
|
+
// QC samples (6 fields)
|
|
37
|
+
'LT_13102025_EQC_Jurkat_1_2',
|
|
38
|
+
'LT_13102025_EQC_Jurkat_2_8',
|
|
39
|
+
'LT_13102025_IQC_Pool_1_5',
|
|
40
|
+
// Test samples (4 fields)
|
|
41
|
+
'test_EQC_Jurkat_02',
|
|
42
|
+
'test_Blank_Run_01',
|
|
43
|
+
]
|
|
44
|
+
|
|
45
|
+
// Mock design_data matching MS Designer's SampleData schema
|
|
46
|
+
const mockDesignData = {
|
|
47
|
+
schema_version: '2.0',
|
|
48
|
+
cell_line: 'HeLa',
|
|
49
|
+
samples: [
|
|
50
|
+
{ plate_id: 'Plate 1', well_id: 'A1', sample_name: 'HeLa_DrugA_24h_Rep1', sample_type: 'sample', conditions: { 'Cell Line': 'HeLa', Treatment: 'Drug A', Timepoint: '24h' } },
|
|
51
|
+
{ plate_id: 'Plate 1', well_id: 'A2', sample_name: 'HeLa_DrugA_24h_Rep2', sample_type: 'sample', conditions: { 'Cell Line': 'HeLa', Treatment: 'Drug A', Timepoint: '24h' } },
|
|
52
|
+
{ plate_id: 'Plate 1', well_id: 'A3', sample_name: 'HeLa_DrugA_24h_Rep3', sample_type: 'sample', conditions: { 'Cell Line': 'HeLa', Treatment: 'Drug A', Timepoint: '24h' } },
|
|
53
|
+
{ plate_id: 'Plate 1', well_id: 'B1', sample_name: 'HeLa_Ctrl_24h_Rep1', sample_type: 'sample', conditions: { 'Cell Line': 'HeLa', Treatment: 'Control', Timepoint: '24h' } },
|
|
54
|
+
{ plate_id: 'Plate 1', well_id: 'B2', sample_name: 'HeLa_Ctrl_24h_Rep2', sample_type: 'sample', conditions: { 'Cell Line': 'HeLa', Treatment: 'Control', Timepoint: '24h' } },
|
|
55
|
+
{ plate_id: 'Plate 1', well_id: 'B3', sample_name: 'HeLa_Ctrl_24h_Rep3', sample_type: 'sample', conditions: { 'Cell Line': 'HeLa', Treatment: 'Control', Timepoint: '24h' } },
|
|
56
|
+
{ plate_id: 'Plate 1', well_id: 'C1', sample_name: 'MCF7_DrugA_24h_Rep1', sample_type: 'sample', conditions: { 'Cell Line': 'MCF7', Treatment: 'Drug A', Timepoint: '24h' } },
|
|
57
|
+
{ plate_id: 'Plate 1', well_id: 'C2', sample_name: 'MCF7_DrugA_24h_Rep2', sample_type: 'sample', conditions: { 'Cell Line': 'MCF7', Treatment: 'Drug A', Timepoint: '24h' } },
|
|
58
|
+
{ plate_id: 'Plate 1', well_id: 'C3', sample_name: 'MCF7_DrugA_24h_Rep3', sample_type: 'sample', conditions: { 'Cell Line': 'MCF7', Treatment: 'Drug A', Timepoint: '24h' } },
|
|
59
|
+
{ plate_id: 'Plate 1', well_id: 'D1', sample_name: 'MCF7_Ctrl_24h_Rep1', sample_type: 'sample', conditions: { 'Cell Line': 'MCF7', Treatment: 'Control', Timepoint: '24h' } },
|
|
60
|
+
{ plate_id: 'Plate 1', well_id: 'D2', sample_name: 'MCF7_Ctrl_24h_Rep2', sample_type: 'sample', conditions: { 'Cell Line': 'MCF7', Treatment: 'Control', Timepoint: '24h' } },
|
|
61
|
+
{ plate_id: 'Plate 1', well_id: 'D3', sample_name: 'MCF7_Ctrl_24h_Rep3', sample_type: 'sample', conditions: { 'Cell Line': 'MCF7', Treatment: 'Control', Timepoint: '24h' } },
|
|
62
|
+
{ plate_id: 'Plate 1', well_id: 'E1', sample_name: 'EQC_Pool_1', sample_type: 'qc', conditions: {} },
|
|
63
|
+
{ plate_id: 'Plate 1', well_id: 'E2', sample_name: 'EQC_Pool_2', sample_type: 'qc', conditions: {} },
|
|
64
|
+
{ plate_id: 'Plate 1', well_id: 'F1', sample_name: 'Blank_1', sample_type: 'blank', conditions: {} },
|
|
65
|
+
],
|
|
66
|
+
plates: [{ name: 'Plate 1', layout_type: '96-well' }],
|
|
67
|
+
extraction_results: [],
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
// Hyphen-delimited samples
|
|
71
|
+
const hyphenSamples = [
|
|
72
|
+
'WT-Vehicle-1', 'WT-Vehicle-2', 'WT-Vehicle-3',
|
|
73
|
+
'WT-Drug-1', 'WT-Drug-2', 'WT-Drug-3',
|
|
74
|
+
'KO-Vehicle-1', 'KO-Vehicle-2', 'KO-Vehicle-3',
|
|
75
|
+
'KO-Drug-1', 'KO-Drug-2', 'KO-Drug-3',
|
|
76
|
+
]
|
|
77
|
+
|
|
78
|
+
const isOpen = ref(false)
|
|
79
|
+
const lastResult = ref<AutoGroupResult | null>(null)
|
|
80
|
+
|
|
81
|
+
function handleApply(result: AutoGroupResult) {
|
|
82
|
+
lastResult.value = result
|
|
83
|
+
console.log('AutoGroupModal result:', result)
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
function initState(samples: string[] = proteomicsSamples) {
|
|
87
|
+
return {
|
|
88
|
+
isOpen: true,
|
|
89
|
+
samples,
|
|
90
|
+
lastResult: null as AutoGroupResult | null,
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
</script>
|
|
94
|
+
|
|
95
|
+
<template>
|
|
96
|
+
<Story title="Lab/AutoGroupModal">
|
|
97
|
+
<Variant title="Playground" :init-state="() => ({ isOpen: false, samples: proteomicsSamples, lastResult: null as AutoGroupResult | null })">
|
|
98
|
+
<template #default="{ state }">
|
|
99
|
+
<div style="padding: 2rem;">
|
|
100
|
+
<button
|
|
101
|
+
type="button"
|
|
102
|
+
style="
|
|
103
|
+
padding: 0.5rem 1rem;
|
|
104
|
+
background: var(--bg-card, #fff);
|
|
105
|
+
border: 1px solid var(--border-color, #e5e7eb);
|
|
106
|
+
border-radius: 0.375rem;
|
|
107
|
+
cursor: pointer;
|
|
108
|
+
font-size: 0.875rem;
|
|
109
|
+
"
|
|
110
|
+
@click="state.isOpen = true"
|
|
111
|
+
>
|
|
112
|
+
Open Auto Group Modal
|
|
113
|
+
</button>
|
|
114
|
+
|
|
115
|
+
<div v-if="state.lastResult" style="margin-top: 1rem; font-size: 0.8125rem; color: var(--text-secondary, #64748b);">
|
|
116
|
+
<strong>Last result:</strong>
|
|
117
|
+
{{ state.lastResult.groups.length }} groups,
|
|
118
|
+
{{ state.lastResult.metadata.length }} samples,
|
|
119
|
+
{{ state.lastResult.excludedSamples.length }} excluded
|
|
120
|
+
</div>
|
|
121
|
+
|
|
122
|
+
<AutoGroupModal
|
|
123
|
+
v-model="state.isOpen"
|
|
124
|
+
:samples="state.samples"
|
|
125
|
+
@apply="(r: AutoGroupResult) => { state.lastResult = r; console.log('Result:', r) }"
|
|
126
|
+
/>
|
|
127
|
+
</div>
|
|
128
|
+
</template>
|
|
129
|
+
<template #controls="{ state }">
|
|
130
|
+
<HstSelect
|
|
131
|
+
:model-value="state.samples === proteomicsSamples ? 'proteomics' : state.samples === withOutliersSamples ? 'outliers' : state.samples === mixedFieldCountSamples ? 'mixed' : 'hyphen'"
|
|
132
|
+
title="Sample Set"
|
|
133
|
+
:options="[
|
|
134
|
+
{ value: 'proteomics', label: 'Proteomics (clean)' },
|
|
135
|
+
{ value: 'outliers', label: 'With QC/Blanks' },
|
|
136
|
+
{ value: 'mixed', label: 'Mixed Field Counts (11 + 6 + 4)' },
|
|
137
|
+
{ value: 'hyphen', label: 'Hyphen-delimited' },
|
|
138
|
+
]"
|
|
139
|
+
@update:model-value="(v: string) => {
|
|
140
|
+
if (v === 'proteomics') state.samples = proteomicsSamples
|
|
141
|
+
else if (v === 'outliers') state.samples = withOutliersSamples
|
|
142
|
+
else if (v === 'mixed') state.samples = mixedFieldCountSamples
|
|
143
|
+
else state.samples = hyphenSamples
|
|
144
|
+
}"
|
|
145
|
+
/>
|
|
146
|
+
</template>
|
|
147
|
+
</Variant>
|
|
148
|
+
|
|
149
|
+
<Variant title="Pre-filled (Proteomics)" :init-state="() => initState(proteomicsSamples)">
|
|
150
|
+
<template #default="{ state }">
|
|
151
|
+
<div style="padding: 2rem;">
|
|
152
|
+
<button
|
|
153
|
+
type="button"
|
|
154
|
+
style="padding: 0.5rem 1rem; background: var(--bg-card, #fff); border: 1px solid var(--border-color, #e5e7eb); border-radius: 0.375rem; cursor: pointer; font-size: 0.875rem;"
|
|
155
|
+
@click="state.isOpen = true"
|
|
156
|
+
>
|
|
157
|
+
Re-open Modal
|
|
158
|
+
</button>
|
|
159
|
+
<AutoGroupModal
|
|
160
|
+
v-model="state.isOpen"
|
|
161
|
+
:samples="state.samples"
|
|
162
|
+
@apply="handleApply"
|
|
163
|
+
/>
|
|
164
|
+
</div>
|
|
165
|
+
</template>
|
|
166
|
+
</Variant>
|
|
167
|
+
|
|
168
|
+
<Variant title="With Outliers (QC/Blanks)" :init-state="() => initState(withOutliersSamples)">
|
|
169
|
+
<template #default="{ state }">
|
|
170
|
+
<div style="padding: 2rem;">
|
|
171
|
+
<button
|
|
172
|
+
type="button"
|
|
173
|
+
style="padding: 0.5rem 1rem; background: var(--bg-card, #fff); border: 1px solid var(--border-color, #e5e7eb); border-radius: 0.375rem; cursor: pointer; font-size: 0.875rem;"
|
|
174
|
+
@click="state.isOpen = true"
|
|
175
|
+
>
|
|
176
|
+
Re-open Modal
|
|
177
|
+
</button>
|
|
178
|
+
<AutoGroupModal
|
|
179
|
+
v-model="state.isOpen"
|
|
180
|
+
:samples="state.samples"
|
|
181
|
+
@apply="handleApply"
|
|
182
|
+
/>
|
|
183
|
+
</div>
|
|
184
|
+
</template>
|
|
185
|
+
</Variant>
|
|
186
|
+
|
|
187
|
+
<Variant title="Mixed Field Counts (Smart Outlier Detection)" :init-state="() => initState(mixedFieldCountSamples)">
|
|
188
|
+
<template #default="{ state }">
|
|
189
|
+
<div style="padding: 2rem;">
|
|
190
|
+
<button
|
|
191
|
+
type="button"
|
|
192
|
+
style="padding: 0.5rem 1rem; background: var(--bg-card, #fff); border: 1px solid var(--border-color, #e5e7eb); border-radius: 0.375rem; cursor: pointer; font-size: 0.875rem;"
|
|
193
|
+
@click="state.isOpen = true"
|
|
194
|
+
>
|
|
195
|
+
Re-open Modal
|
|
196
|
+
</button>
|
|
197
|
+
<AutoGroupModal
|
|
198
|
+
v-model="state.isOpen"
|
|
199
|
+
:samples="state.samples"
|
|
200
|
+
@apply="handleApply"
|
|
201
|
+
/>
|
|
202
|
+
</div>
|
|
203
|
+
</template>
|
|
204
|
+
</Variant>
|
|
205
|
+
|
|
206
|
+
<Variant title="Hyphen-Delimited" :init-state="() => initState(hyphenSamples)">
|
|
207
|
+
<template #default="{ state }">
|
|
208
|
+
<div style="padding: 2rem;">
|
|
209
|
+
<button
|
|
210
|
+
type="button"
|
|
211
|
+
style="padding: 0.5rem 1rem; background: var(--bg-card, #fff); border: 1px solid var(--border-color, #e5e7eb); border-radius: 0.375rem; cursor: pointer; font-size: 0.875rem;"
|
|
212
|
+
@click="state.isOpen = true"
|
|
213
|
+
>
|
|
214
|
+
Re-open Modal
|
|
215
|
+
</button>
|
|
216
|
+
<AutoGroupModal
|
|
217
|
+
v-model="state.isOpen"
|
|
218
|
+
:samples="state.samples"
|
|
219
|
+
@apply="handleApply"
|
|
220
|
+
/>
|
|
221
|
+
</div>
|
|
222
|
+
</template>
|
|
223
|
+
</Variant>
|
|
224
|
+
|
|
225
|
+
<Variant title="From Experiment Metadata" :init-state="() => ({ isOpen: true, lastResult: null as AutoGroupResult | null })">
|
|
226
|
+
<template #default="{ state }">
|
|
227
|
+
<div style="padding: 2rem;">
|
|
228
|
+
<button
|
|
229
|
+
type="button"
|
|
230
|
+
style="padding: 0.5rem 1rem; background: var(--bg-card, #fff); border: 1px solid var(--border-color, #e5e7eb); border-radius: 0.375rem; cursor: pointer; font-size: 0.875rem;"
|
|
231
|
+
@click="state.isOpen = true"
|
|
232
|
+
>
|
|
233
|
+
Re-open Modal
|
|
234
|
+
</button>
|
|
235
|
+
<div v-if="state.lastResult" style="margin-top: 1rem; font-size: 0.8125rem; color: var(--text-secondary, #64748b);">
|
|
236
|
+
<strong>Last result:</strong>
|
|
237
|
+
{{ state.lastResult.groups.length }} groups,
|
|
238
|
+
{{ state.lastResult.metadata.length }} samples,
|
|
239
|
+
{{ state.lastResult.excludedSamples.length }} excluded
|
|
240
|
+
</div>
|
|
241
|
+
<AutoGroupModal
|
|
242
|
+
v-model="state.isOpen"
|
|
243
|
+
:design-data="mockDesignData"
|
|
244
|
+
@apply="(r: AutoGroupResult) => { state.lastResult = r }"
|
|
245
|
+
/>
|
|
246
|
+
</div>
|
|
247
|
+
</template>
|
|
248
|
+
</Variant>
|
|
249
|
+
|
|
250
|
+
<Variant title="Empty (Manual Paste)">
|
|
251
|
+
<div style="padding: 2rem;">
|
|
252
|
+
<button
|
|
253
|
+
type="button"
|
|
254
|
+
style="
|
|
255
|
+
padding: 0.5rem 1rem;
|
|
256
|
+
background: var(--bg-card, #fff);
|
|
257
|
+
border: 1px solid var(--border-color, #e5e7eb);
|
|
258
|
+
border-radius: 0.375rem;
|
|
259
|
+
cursor: pointer;
|
|
260
|
+
font-size: 0.875rem;
|
|
261
|
+
"
|
|
262
|
+
@click="isOpen = true"
|
|
263
|
+
>
|
|
264
|
+
Open Empty Modal (paste your own samples)
|
|
265
|
+
</button>
|
|
266
|
+
<AutoGroupModal
|
|
267
|
+
v-model="isOpen"
|
|
268
|
+
@apply="handleApply"
|
|
269
|
+
/>
|
|
270
|
+
</div>
|
|
271
|
+
</Variant>
|
|
272
|
+
</Story>
|
|
273
|
+
</template>
|