@morscherlab/mint-sdk 1.3.0-beta.3 → 1.3.0-beta.5
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 +23 -140
- package/dist/{ResourcePickerListInternal-c3IT8PIu.js → ResourcePickerListInternal-BEXnyBNz.js} +7 -3
- package/dist/ResourcePickerListInternal-BEXnyBNz.js.map +1 -0
- package/dist/components/FilePicker.vue.d.ts +4 -1
- package/dist/components/WellPlate.colors.d.ts +1 -5
- package/dist/components/WellPlate.rendering.d.ts +5 -2
- package/dist/components/index.d.ts +32 -17
- package/dist/components/index.js +3 -3
- package/dist/components/internal/FilePickerListInternal.vue.d.ts +2 -0
- package/dist/{components-CvY105kJ.js → components-BTzcqrJp.js} +400 -358
- package/dist/components-BTzcqrJp.js.map +1 -0
- package/dist/composables/createFilePickerAdapter.d.ts +5 -1
- package/dist/composables/filePicker/usePickerNavigation.d.ts +3 -2
- package/dist/composables/index.d.ts +0 -3
- package/dist/composables/index.js +4 -4
- package/dist/composables/useAutoGroup.d.ts +1 -1
- package/dist/composables/useBioTemplateComponents.d.ts +15 -3
- package/dist/composables/useBioTemplateControls.d.ts +5 -1
- package/dist/composables/useBioTemplatePackWorkspace.d.ts +2 -0
- package/dist/composables/useBioTemplatePresetWorkspace.d.ts +5 -1
- package/dist/composables/useBioTemplateWorkspace.d.ts +5 -1
- package/dist/composables/useExperimentSave.d.ts +5 -1
- package/dist/composables/useFilePicker.d.ts +4 -1
- package/dist/composables/useGroupAssignment.d.ts +5 -1
- package/dist/composables/useTemplateCollection.d.ts +5 -1
- package/dist/composables-Doqb7g1z.js +591 -0
- package/dist/composables-Doqb7g1z.js.map +1 -0
- package/dist/index.js +24 -24
- package/dist/index.js.map +1 -1
- package/dist/install.js +1 -1
- package/dist/lcms.d.ts +11 -11
- package/dist/styles.css +60 -89
- package/dist/templates/index.js +1 -1
- package/dist/{templates-Bj9hZ7iV.js → templates-DgAG5kMq.js} +2 -2
- package/dist/{templates-Bj9hZ7iV.js.map → templates-DgAG5kMq.js.map} +1 -1
- package/dist/types/auth.d.ts +0 -27
- package/dist/types/components.d.ts +4 -0
- package/dist/types/fileBrowserTypes.d.ts +13 -0
- package/dist/types/filePicker.d.ts +8 -1
- package/dist/types/index.d.ts +2 -2
- package/dist/utils/rack.d.ts +16 -16
- package/dist/{validation-B4Y8_eEe.js → validation-DILksa0c.js} +50 -12
- package/dist/validation-DILksa0c.js.map +1 -0
- package/package.json +1 -6
- package/src/__tests__/components/ActionMenu.test.ts +10 -0
- package/src/__tests__/components/AppTopBar.test.ts +16 -8
- package/src/__tests__/components/EmptyState.test.ts +15 -0
- package/src/__tests__/components/FilePicker.test.ts +65 -1
- package/src/__tests__/components/WellPlate.decoration.test.ts +4 -28
- package/src/__tests__/components/WellPlate.rendering.test.ts +20 -33
- package/src/__tests__/components/WellPlate.sampleTypeIndicator.test.ts +7 -7
- package/src/__tests__/composables/createFilePickerAdapter.test.ts +92 -1
- package/src/__tests__/composables/usePickerNavigation.test.ts +61 -1
- package/src/__tests__/composables/usePlatformFilePickerAdapter.test.ts +18 -6
- package/src/__tests__/docs/frontendDocsCatalog.test.ts +2 -2
- package/src/__tests__/styles/controlRefreshRules.test.ts +0 -6
- package/src/__tests__/styles/menusShellRefresh.test.ts +8 -2
- package/src/__tests__/templates/templatesDeprecation.test.ts +51 -11
- package/src/components/ActionMenu.vue +10 -2
- package/src/components/AppTopBar.vue +2 -4
- package/src/components/EmptyState.vue +3 -1
- package/src/components/FilePicker.vue +42 -0
- package/src/components/WellPlate.colors.ts +6 -10
- package/src/components/WellPlate.legend.ts +4 -4
- package/src/components/WellPlate.rendering.ts +9 -8
- package/src/components/WellPlate.vue +5 -22
- package/src/components/index.ts +32 -17
- package/src/components/internal/FilePickerListInternal.vue +11 -2
- package/src/composables/autoGroup/index.ts +1 -1
- package/src/composables/createFilePickerAdapter.ts +82 -22
- package/src/composables/filePicker/usePickerNavigation.ts +29 -2
- package/src/composables/index.ts +0 -7
- package/src/composables/useAutoGroup.ts +1 -1
- package/src/composables/useBioTemplateComponents.ts +15 -3
- package/src/composables/useBioTemplateControls.ts +5 -1
- package/src/composables/useBioTemplatePackWorkspace.ts +2 -0
- package/src/composables/useBioTemplatePresetWorkspace.ts +5 -1
- package/src/composables/useBioTemplateWorkspace.ts +5 -1
- package/src/composables/useExperimentSave.ts +5 -1
- package/src/composables/useFilePicker.ts +8 -1
- package/src/composables/useGroupAssignment.ts +5 -1
- package/src/composables/usePlatformFilePickerAdapter.ts +26 -4
- package/src/composables/useTemplateCollection.ts +5 -1
- package/src/index.ts +1 -1
- package/src/lcms.ts +11 -11
- package/src/styles/components/action-menu.css +10 -0
- package/src/styles/components/app-top-bar.css +7 -31
- package/src/styles/components/empty-state.css +3 -2
- package/src/styles/components/file-picker.css +23 -1
- package/src/styles/components/well-plate.css +18 -55
- package/src/types/auth.ts +0 -37
- package/src/types/components.ts +4 -0
- package/src/types/fileBrowserTypes.ts +15 -0
- package/src/types/filePicker.ts +8 -1
- package/src/types/index.ts +2 -5
- package/src/utils/rack.ts +16 -16
- package/dist/ResourcePickerListInternal-c3IT8PIu.js.map +0 -1
- package/dist/__tests__/composables/useAuth.test.d.ts +0 -1
- package/dist/__tests__/composables/usePasskey.test.d.ts +0 -1
- package/dist/components-CvY105kJ.js.map +0 -1
- package/dist/composables/useAuth.d.ts +0 -47
- package/dist/composables/usePasskey.d.ts +0 -10
- package/dist/composables/useWellPlateEditor.d.ts +0 -33
- package/dist/composables-DL4Vca7L.js +0 -1193
- package/dist/composables-DL4Vca7L.js.map +0 -1
- package/dist/plotly.min-D6Ge6qgX.js +0 -168582
- package/dist/plotly.min-D6Ge6qgX.js.map +0 -1
- package/dist/validation-B4Y8_eEe.js.map +0 -1
- package/src/__tests__/composables/useAuth.test.ts +0 -290
- package/src/__tests__/composables/usePasskey.test.ts +0 -38
- package/src/composables/useAuth.ts +0 -470
- package/src/composables/usePasskey.ts +0 -216
- package/src/composables/useWellPlateEditor.ts +0 -415
|
@@ -39,29 +39,18 @@
|
|
|
39
39
|
flex-shrink: 0;
|
|
40
40
|
}
|
|
41
41
|
|
|
42
|
+
/* Slotted logos sized above 32px shrink to fit instead of turning into a 32x36 tile. */
|
|
43
|
+
.mint-topbar__identity > * {
|
|
44
|
+
max-width: 100%;
|
|
45
|
+
max-height: 100%;
|
|
46
|
+
}
|
|
47
|
+
|
|
42
48
|
/* The 36px plugin tile would push the bar past 52px; the bar uses the 32px control height. */
|
|
43
49
|
.mint-topbar__identity .mint-plugin-icon--topbar {
|
|
44
50
|
width: 2rem;
|
|
45
51
|
height: 2rem;
|
|
46
52
|
}
|
|
47
53
|
|
|
48
|
-
/* Integrated: the tile joins the static identity as a 20px mark (icon + name + version). */
|
|
49
|
-
.mint-topbar__brand:has(+ .mint-topbar__plugin-identity) .mint-topbar__identity {
|
|
50
|
-
width: auto;
|
|
51
|
-
padding-left: 0.125rem;
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
.mint-topbar__brand:has(+ .mint-topbar__plugin-identity) .mint-plugin-icon--topbar {
|
|
55
|
-
width: 1.25rem;
|
|
56
|
-
height: 1.25rem;
|
|
57
|
-
border-radius: var(--radius-sm);
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
.mint-topbar__brand:has(+ .mint-topbar__plugin-identity) .mint-plugin-icon--topbar :is(.mint-plugin-icon__svg, .mint-plugin-icon__img) {
|
|
61
|
-
width: 0.75rem;
|
|
62
|
-
height: 0.75rem;
|
|
63
|
-
}
|
|
64
|
-
|
|
65
54
|
/* Centered section — absolute so asymmetric left/right weight never shifts the
|
|
66
55
|
pill-nav off the topbar midline. Pointer-events: none lets the pill-nav
|
|
67
56
|
overlay the background while remaining interactive via its own children. */
|
|
@@ -118,7 +107,7 @@
|
|
|
118
107
|
color: var(--text-primary);
|
|
119
108
|
}
|
|
120
109
|
|
|
121
|
-
/* Static plugin identity: name
|
|
110
|
+
/* Static plugin identity: name only, not a control (5a) */
|
|
122
111
|
.mint-topbar__plugin-identity {
|
|
123
112
|
display: inline-flex;
|
|
124
113
|
align-items: baseline;
|
|
@@ -136,19 +125,6 @@
|
|
|
136
125
|
text-overflow: ellipsis;
|
|
137
126
|
}
|
|
138
127
|
|
|
139
|
-
.mint-topbar__plugin-version {
|
|
140
|
-
font-family: var(--font-mono);
|
|
141
|
-
font-size: 0.6875rem;
|
|
142
|
-
color: var(--text-secondary);
|
|
143
|
-
}
|
|
144
|
-
|
|
145
|
-
.mint-topbar__divider {
|
|
146
|
-
width: 1px;
|
|
147
|
-
height: 1.25rem;
|
|
148
|
-
flex-shrink: 0;
|
|
149
|
-
background-color: var(--border-color);
|
|
150
|
-
}
|
|
151
|
-
|
|
152
128
|
/* Variant: card - inline card with margins and rounded corners */
|
|
153
129
|
.mint-topbar--card {
|
|
154
130
|
width: calc(100% - 2rem);
|
|
@@ -115,8 +115,9 @@
|
|
|
115
115
|
color: var(--text-muted);
|
|
116
116
|
}
|
|
117
117
|
|
|
118
|
-
/* Action */
|
|
119
|
-
.mint-empty-state--illustrated .mint-empty-state__action
|
|
118
|
+
/* Action — slotted content sits in a block so a child's own larger top margin collapses into this one. */
|
|
119
|
+
.mint-empty-state--illustrated .mint-empty-state__action,
|
|
120
|
+
.mint-empty-state--illustrated .mint-empty-state__content {
|
|
120
121
|
margin-top: 0.625rem;
|
|
121
122
|
}
|
|
122
123
|
|
|
@@ -106,6 +106,7 @@
|
|
|
106
106
|
white-space: nowrap;
|
|
107
107
|
}
|
|
108
108
|
.mint-picker__scope,
|
|
109
|
+
.mint-picker__sort,
|
|
109
110
|
.mint-picker__link {
|
|
110
111
|
padding: 2px 6px;
|
|
111
112
|
border: 0;
|
|
@@ -116,10 +117,20 @@
|
|
|
116
117
|
cursor: pointer;
|
|
117
118
|
transition: background-color 150ms ease;
|
|
118
119
|
}
|
|
119
|
-
.mint-picker__scope
|
|
120
|
+
.mint-picker__scope,
|
|
121
|
+
.mint-picker__sort {
|
|
120
122
|
flex-shrink: 0;
|
|
121
123
|
color: var(--text-secondary-strong);
|
|
122
124
|
}
|
|
125
|
+
.mint-picker__sort {
|
|
126
|
+
display: inline-flex;
|
|
127
|
+
align-items: center;
|
|
128
|
+
gap: 2px;
|
|
129
|
+
}
|
|
130
|
+
.mint-picker__sort svg {
|
|
131
|
+
width: 12px;
|
|
132
|
+
height: 12px;
|
|
133
|
+
}
|
|
123
134
|
.mint-picker__link {
|
|
124
135
|
color: var(--_ink-primary);
|
|
125
136
|
}
|
|
@@ -138,10 +149,13 @@
|
|
|
138
149
|
cursor: not-allowed;
|
|
139
150
|
}
|
|
140
151
|
.mint-picker__scope:hover,
|
|
152
|
+
.mint-picker__sort:hover,
|
|
153
|
+
.mint-picker__sort[aria-expanded='true'],
|
|
141
154
|
.mint-picker__link:hover {
|
|
142
155
|
background: var(--bg-hover);
|
|
143
156
|
}
|
|
144
157
|
.mint-picker__scope:focus-visible,
|
|
158
|
+
.mint-picker__sort:focus-visible,
|
|
145
159
|
.mint-picker__link:focus-visible {
|
|
146
160
|
outline: none;
|
|
147
161
|
box-shadow: var(--focus-ring-offset);
|
|
@@ -185,6 +199,14 @@
|
|
|
185
199
|
.mint-picker__list-head > span:nth-child(n + 3) {
|
|
186
200
|
text-align: right;
|
|
187
201
|
}
|
|
202
|
+
.mint-picker__truncated {
|
|
203
|
+
margin: 0;
|
|
204
|
+
padding: 6px 12px;
|
|
205
|
+
border-bottom: 1px solid var(--border-light);
|
|
206
|
+
background: var(--bg-secondary);
|
|
207
|
+
font-size: 12px;
|
|
208
|
+
color: var(--text-secondary);
|
|
209
|
+
}
|
|
188
210
|
.mint-picker__row {
|
|
189
211
|
box-sizing: border-box;
|
|
190
212
|
height: 34px;
|
|
@@ -59,10 +59,9 @@
|
|
|
59
59
|
/* Header cells */
|
|
60
60
|
.mint-well-plate__col-header,
|
|
61
61
|
.mint-well-plate__row-header {
|
|
62
|
-
font-
|
|
63
|
-
font-weight: 400;
|
|
62
|
+
font-weight: 500;
|
|
64
63
|
text-align: center;
|
|
65
|
-
color: var(--text-
|
|
64
|
+
color: var(--text-muted);
|
|
66
65
|
}
|
|
67
66
|
|
|
68
67
|
.mint-well-plate__row-header {
|
|
@@ -83,9 +82,8 @@
|
|
|
83
82
|
font-weight: 500;
|
|
84
83
|
cursor: pointer;
|
|
85
84
|
transition: background-color 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease, opacity 0.15s ease;
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
border: 1px solid color-mix(in srgb, var(--text-secondary) 35%, var(--border-color));
|
|
85
|
+
background-color: var(--bg-tertiary);
|
|
86
|
+
border: 1px dashed var(--border-color);
|
|
89
87
|
}
|
|
90
88
|
|
|
91
89
|
.mint-well-plate__well--rounded {
|
|
@@ -97,7 +95,7 @@
|
|
|
97
95
|
}
|
|
98
96
|
|
|
99
97
|
.mint-well-plate__well--filled {
|
|
100
|
-
|
|
98
|
+
border-style: solid;
|
|
101
99
|
}
|
|
102
100
|
|
|
103
101
|
.mint-well-plate__well--disabled {
|
|
@@ -106,29 +104,27 @@
|
|
|
106
104
|
}
|
|
107
105
|
|
|
108
106
|
/* Well states */
|
|
109
|
-
/* Neutral ring + shape only, so a ring never vanishes into a sample color (2b). */
|
|
110
107
|
.mint-well-plate__well--selected {
|
|
111
|
-
box-shadow: 0 0 0 2px var(--
|
|
108
|
+
box-shadow: 0 0 0 2px var(--mint-success), 0 0 0 3px var(--bg-card);
|
|
112
109
|
}
|
|
113
110
|
|
|
114
111
|
.mint-well-plate__well--drag-over {
|
|
115
112
|
box-shadow: 0 0 0 2px var(--color-primary);
|
|
116
|
-
background-color: var(--color-primary
|
|
113
|
+
background-color: color-mix(in srgb, var(--color-primary) 20%, transparent);
|
|
117
114
|
}
|
|
118
115
|
|
|
119
116
|
.mint-well-plate__well--hovered {
|
|
120
|
-
box-shadow: 0 0 0
|
|
117
|
+
box-shadow: 0 0 0 2px color-mix(in srgb, var(--mint-success) 50%, transparent);
|
|
121
118
|
}
|
|
122
119
|
|
|
123
|
-
/* !important: wellStyle() sets an inline solid `border` on every draggable well. */
|
|
124
120
|
.mint-well-plate__well--drag-source {
|
|
125
|
-
|
|
121
|
+
box-shadow: 0 0 0 2px var(--mint-warning);
|
|
126
122
|
opacity: 0.5;
|
|
127
123
|
}
|
|
128
124
|
|
|
129
125
|
.mint-well-plate__well--drag-target {
|
|
130
|
-
box-shadow: 0 0 0 2px var(--
|
|
131
|
-
background-color: var(--
|
|
126
|
+
box-shadow: 0 0 0 2px var(--mint-success), 0 0 0 3px var(--bg-card);
|
|
127
|
+
background-color: color-mix(in srgb, var(--mint-success) 20%, transparent);
|
|
132
128
|
}
|
|
133
129
|
|
|
134
130
|
/* Optional semantic classes for `wellClass` callbacks. */
|
|
@@ -168,18 +164,6 @@
|
|
|
168
164
|
color: var(--text-primary);
|
|
169
165
|
}
|
|
170
166
|
|
|
171
|
-
/* Q / i marker glyph when the centre holds a label or well ID (iQC has no other cue) */
|
|
172
|
-
.mint-well-plate__corner-glyph {
|
|
173
|
-
position: absolute;
|
|
174
|
-
top: 3px;
|
|
175
|
-
left: 6px;
|
|
176
|
-
font-size: 10px;
|
|
177
|
-
font-weight: 700;
|
|
178
|
-
line-height: 1;
|
|
179
|
-
pointer-events: none;
|
|
180
|
-
color: var(--text-primary);
|
|
181
|
-
}
|
|
182
|
-
|
|
183
167
|
/* Well ID text */
|
|
184
168
|
.mint-well-plate__well-id {
|
|
185
169
|
font-weight: 500;
|
|
@@ -268,34 +252,21 @@
|
|
|
268
252
|
/* Badge (injection count / custom method indicator) */
|
|
269
253
|
.mint-well-plate__badge {
|
|
270
254
|
position: absolute;
|
|
271
|
-
top: -
|
|
272
|
-
right: -
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
height: 14px;
|
|
276
|
-
padding: 0 3px;
|
|
255
|
+
top: -4px;
|
|
256
|
+
right: -4px;
|
|
257
|
+
width: 16px;
|
|
258
|
+
height: 16px;
|
|
277
259
|
border-radius: 9999px;
|
|
278
|
-
|
|
279
|
-
font-family: var(--font-mono);
|
|
280
|
-
font-size: 9px;
|
|
260
|
+
font-size: 10px;
|
|
281
261
|
font-weight: 700;
|
|
282
262
|
display: flex;
|
|
283
263
|
align-items: center;
|
|
284
264
|
justify-content: center;
|
|
285
|
-
color:
|
|
265
|
+
color: white;
|
|
286
266
|
pointer-events: none;
|
|
287
267
|
line-height: 1;
|
|
288
268
|
}
|
|
289
269
|
|
|
290
|
-
/* Custom method: a plain dot (7a) */
|
|
291
|
-
.mint-well-plate__badge--dot {
|
|
292
|
-
top: -2px;
|
|
293
|
-
right: -2px;
|
|
294
|
-
min-width: 8px;
|
|
295
|
-
height: 8px;
|
|
296
|
-
padding: 0;
|
|
297
|
-
}
|
|
298
|
-
|
|
299
270
|
/* Sample type legend bar */
|
|
300
271
|
.mint-well-plate__sample-legend {
|
|
301
272
|
margin-top: 0.5rem;
|
|
@@ -312,23 +283,15 @@
|
|
|
312
283
|
}
|
|
313
284
|
|
|
314
285
|
.mint-well-plate__sample-legend-dot {
|
|
315
|
-
display: inline-flex;
|
|
316
|
-
align-items: center;
|
|
317
|
-
justify-content: center;
|
|
318
|
-
box-sizing: border-box;
|
|
319
286
|
width: 0.875rem;
|
|
320
287
|
height: 0.875rem;
|
|
321
288
|
border-radius: var(--radius-sm);
|
|
322
289
|
flex-shrink: 0;
|
|
323
|
-
font-family: var(--font-mono);
|
|
324
|
-
font-size: 0.625rem;
|
|
325
|
-
font-weight: 600;
|
|
326
|
-
line-height: 1;
|
|
327
290
|
}
|
|
328
291
|
|
|
329
292
|
.mint-well-plate__sample-legend-text {
|
|
330
293
|
font-size: 0.75rem;
|
|
331
|
-
color: var(--text-
|
|
294
|
+
color: var(--text-muted);
|
|
332
295
|
}
|
|
333
296
|
|
|
334
297
|
/* Empty / loading / error placeholder host (content comes from EmptyState) */
|
package/src/types/auth.ts
CHANGED
|
@@ -20,40 +20,3 @@ export interface UserInfo {
|
|
|
20
20
|
roleObj?: RoleInfo | null
|
|
21
21
|
isActive: boolean
|
|
22
22
|
}
|
|
23
|
-
|
|
24
|
-
// Login response from API
|
|
25
|
-
export interface LoginResponse {
|
|
26
|
-
access_token: string
|
|
27
|
-
token_type: string
|
|
28
|
-
expires_in: number
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
// Token verification response
|
|
32
|
-
export interface TokenVerifyResponse {
|
|
33
|
-
valid: boolean
|
|
34
|
-
username: string | null
|
|
35
|
-
expires_at: string | null
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
// Registration request
|
|
39
|
-
export interface RegisterRequest {
|
|
40
|
-
username: string
|
|
41
|
-
password: string
|
|
42
|
-
email?: string
|
|
43
|
-
shortname?: string
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
// Profile update request
|
|
47
|
-
export interface UpdateProfileRequest {
|
|
48
|
-
email?: string
|
|
49
|
-
shortname?: string
|
|
50
|
-
current_password?: string
|
|
51
|
-
new_password?: string
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
// Passkey credential info
|
|
55
|
-
export interface CredentialInfo {
|
|
56
|
-
credential_id: string
|
|
57
|
-
device_name: string | null
|
|
58
|
-
created_at: string
|
|
59
|
-
}
|
package/src/types/components.ts
CHANGED
|
@@ -13,6 +13,8 @@ interface ActionMenuItemBase {
|
|
|
13
13
|
label: string
|
|
14
14
|
disabled?: boolean
|
|
15
15
|
danger?: boolean
|
|
16
|
+
/** Set on every item to make the menu a single choice (`menuitemradio`); true marks the current one. */
|
|
17
|
+
checked?: boolean
|
|
16
18
|
}
|
|
17
19
|
|
|
18
20
|
export type ActionMenuItem =
|
|
@@ -23,6 +25,8 @@ export type ActionMenuItem =
|
|
|
23
25
|
| (ActionMenuItemBase & {
|
|
24
26
|
href: string
|
|
25
27
|
target?: '_self' | '_blank' | '_parent' | '_top'
|
|
28
|
+
/** Links navigate; only buttons can be single-choice items. */
|
|
29
|
+
checked?: never
|
|
26
30
|
})
|
|
27
31
|
|
|
28
32
|
// Input types
|
|
@@ -83,3 +83,18 @@ export interface FileBrowserLocation {
|
|
|
83
83
|
mount_id: string
|
|
84
84
|
path: string
|
|
85
85
|
}
|
|
86
|
+
|
|
87
|
+
/** Several directory levels in one response, parents before children. */
|
|
88
|
+
export interface FileDirectoryTree {
|
|
89
|
+
listings?: FileDirectoryListing[]
|
|
90
|
+
/** True when the server's entry budget stopped before the requested depth. */
|
|
91
|
+
truncated?: boolean
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
/** Entries whose name contains a query, below one directory. */
|
|
95
|
+
export interface FileSearchResult {
|
|
96
|
+
entries?: FileEntry[]
|
|
97
|
+
searched_directories?: number
|
|
98
|
+
/** True when a directory, result or time budget ended the search early. */
|
|
99
|
+
truncated?: boolean
|
|
100
|
+
}
|
package/src/types/filePicker.ts
CHANGED
|
@@ -3,6 +3,8 @@ export type PickerSource = 'server' | 'localFile'
|
|
|
3
3
|
export type PickerSelectionMode = 'single-file' | 'multi-file' | 'folder' | 'folder+files'
|
|
4
4
|
/** `list` shows one folder at a time (the default); `tree` adds disclosure triangles. */
|
|
5
5
|
export type PickerView = 'list' | 'tree'
|
|
6
|
+
/** Row order inside each folder; folders always come before files. */
|
|
7
|
+
export type PickerSort = 'newest' | 'oldest' | 'name' | 'name-desc'
|
|
6
8
|
|
|
7
9
|
interface PickerNodeBase {
|
|
8
10
|
path: string
|
|
@@ -39,6 +41,11 @@ export interface PickerRequest {
|
|
|
39
41
|
*/
|
|
40
42
|
refresh?: true
|
|
41
43
|
}
|
|
44
|
+
/** What a search found before a server or walk limit stopped it. */
|
|
45
|
+
export interface PickerSearchResult {
|
|
46
|
+
nodes: PickerNode[]
|
|
47
|
+
truncated: boolean
|
|
48
|
+
}
|
|
42
49
|
export interface PickerAdapter {
|
|
43
50
|
/**
|
|
44
51
|
* `listRoot()` returns mount points. FilePicker then shows them as header
|
|
@@ -55,7 +62,7 @@ export interface PickerAdapter {
|
|
|
55
62
|
query: string,
|
|
56
63
|
scope: { path: string; recursive: boolean },
|
|
57
64
|
request?: PickerRequest,
|
|
58
|
-
): Promise<PickerNode[]>
|
|
65
|
+
): Promise<PickerNode[] | PickerSearchResult>
|
|
59
66
|
}
|
|
60
67
|
export interface PickerCapability {
|
|
61
68
|
/** Case-insensitive suffixes, including compound extensions such as mzML.gz. */
|
package/src/types/index.ts
CHANGED
|
@@ -218,9 +218,11 @@ export type {
|
|
|
218
218
|
FileBrowserLocation,
|
|
219
219
|
FileBrowserSortKey,
|
|
220
220
|
FileDirectoryListing,
|
|
221
|
+
FileDirectoryTree,
|
|
221
222
|
FileEntry,
|
|
222
223
|
FileEntryKind,
|
|
223
224
|
FilePathCrumb,
|
|
225
|
+
FileSearchResult,
|
|
224
226
|
FileSelection,
|
|
225
227
|
ServerMount,
|
|
226
228
|
} from './fileBrowserTypes'
|
|
@@ -296,11 +298,6 @@ export type {
|
|
|
296
298
|
export type {
|
|
297
299
|
AuthConfig,
|
|
298
300
|
UserInfo,
|
|
299
|
-
LoginResponse,
|
|
300
|
-
TokenVerifyResponse,
|
|
301
|
-
RegisterRequest,
|
|
302
|
-
UpdateProfileRequest,
|
|
303
|
-
CredentialInfo,
|
|
304
301
|
} from './auth'
|
|
305
302
|
|
|
306
303
|
// Platform types
|
package/src/utils/rack.ts
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import type { Rack, SlotPosition, Well, WellEditData, WellPlateFormat } from '../types'
|
|
2
2
|
|
|
3
|
-
/** @deprecated Scheduled for removal in MINT 1.4;
|
|
3
|
+
/** @deprecated Scheduled for removal in MINT 1.4; no SDK replacement. */
|
|
4
4
|
export type LcmsPlateType = '96well' | '54vial'
|
|
5
|
-
/** @deprecated Scheduled for removal in MINT 1.4;
|
|
5
|
+
/** @deprecated Scheduled for removal in MINT 1.4; no SDK replacement. */
|
|
6
6
|
export type LcmsControlSampleType = 'blank' | 'qc' | 'iqc'
|
|
7
7
|
|
|
8
|
-
/** @deprecated Scheduled for removal in MINT 1.4;
|
|
8
|
+
/** @deprecated Scheduled for removal in MINT 1.4; no SDK replacement. */
|
|
9
9
|
export interface LcmsPlateCell {
|
|
10
10
|
row: string
|
|
11
11
|
column: number
|
|
@@ -17,7 +17,7 @@ export interface LcmsPlateCell {
|
|
|
17
17
|
slot?: SlotPosition | null
|
|
18
18
|
}
|
|
19
19
|
|
|
20
|
-
/** @deprecated Scheduled for removal in MINT 1.4;
|
|
20
|
+
/** @deprecated Scheduled for removal in MINT 1.4; no SDK replacement. */
|
|
21
21
|
export interface LcmsPlateCellsToRackOptions {
|
|
22
22
|
rackId?: string
|
|
23
23
|
rackName?: string
|
|
@@ -27,14 +27,14 @@ export interface LcmsPlateCellsToRackOptions {
|
|
|
27
27
|
injectionVolume?: number
|
|
28
28
|
}
|
|
29
29
|
|
|
30
|
-
/** @deprecated Scheduled for removal in MINT 1.4;
|
|
30
|
+
/** @deprecated Scheduled for removal in MINT 1.4; no SDK replacement. */
|
|
31
31
|
export interface LcmsPlateCellsToRacksOptions extends Omit<LcmsPlateCellsToRackOptions, 'rackId' | 'rackName' | 'slot'> {
|
|
32
32
|
defaultSlot?: SlotPosition
|
|
33
33
|
rackId?: (slot: SlotPosition, index: number) => string
|
|
34
34
|
rackName?: (slot: SlotPosition, index: number) => string
|
|
35
35
|
}
|
|
36
36
|
|
|
37
|
-
/** @deprecated Scheduled for removal in MINT 1.4;
|
|
37
|
+
/** @deprecated Scheduled for removal in MINT 1.4; no SDK replacement. */
|
|
38
38
|
export const LCMS_DEFAULT_CONTROL_POSITIONS: Record<LcmsPlateType, Record<LcmsControlSampleType, { row: string; column: number }>> = {
|
|
39
39
|
'96well': {
|
|
40
40
|
blank: { row: 'H', column: 12 },
|
|
@@ -50,24 +50,24 @@ export const LCMS_DEFAULT_CONTROL_POSITIONS: Record<LcmsPlateType, Record<LcmsCo
|
|
|
50
50
|
|
|
51
51
|
const SLOT_ORDER: SlotPosition[] = ['R', 'G', 'B', 'Y']
|
|
52
52
|
|
|
53
|
-
/** @deprecated Scheduled for removal in MINT 1.4;
|
|
53
|
+
/** @deprecated Scheduled for removal in MINT 1.4; no SDK replacement. */
|
|
54
54
|
export function lcmsPlateTypeToRackFormat(plateType: LcmsPlateType): WellPlateFormat {
|
|
55
55
|
return plateType === '96well' ? 96 : 54
|
|
56
56
|
}
|
|
57
57
|
|
|
58
|
-
/** @deprecated Scheduled for removal in MINT 1.4;
|
|
58
|
+
/** @deprecated Scheduled for removal in MINT 1.4; no SDK replacement. */
|
|
59
59
|
export function rackFormatToLcmsPlateType(format: WellPlateFormat): LcmsPlateType {
|
|
60
60
|
if (format === 96) return '96well'
|
|
61
61
|
if (format === 54) return '54vial'
|
|
62
62
|
throw new Error(`LCMS plate cells support only 54-vial racks and 96-well plates; received format ${format}.`)
|
|
63
63
|
}
|
|
64
64
|
|
|
65
|
-
/** @deprecated Scheduled for removal in MINT 1.4;
|
|
65
|
+
/** @deprecated Scheduled for removal in MINT 1.4; no SDK replacement. */
|
|
66
66
|
export function lcmsWellId(row: string, column: number): string {
|
|
67
67
|
return `${row.toUpperCase()}${column}`
|
|
68
68
|
}
|
|
69
69
|
|
|
70
|
-
/** @deprecated Scheduled for removal in MINT 1.4;
|
|
70
|
+
/** @deprecated Scheduled for removal in MINT 1.4; no SDK replacement. */
|
|
71
71
|
export function parseLcmsWellId(wellId: string): { row: string; column: number } {
|
|
72
72
|
const match = /^([A-Za-z]+)(\d+)$/.exec(wellId.trim())
|
|
73
73
|
if (!match) {
|
|
@@ -80,7 +80,7 @@ export function parseLcmsWellId(wellId: string): { row: string; column: number }
|
|
|
80
80
|
}
|
|
81
81
|
}
|
|
82
82
|
|
|
83
|
-
/** @deprecated Scheduled for removal in MINT 1.4;
|
|
83
|
+
/** @deprecated Scheduled for removal in MINT 1.4; no SDK replacement. */
|
|
84
84
|
export function lcmsPlateCellsToRack(cells: LcmsPlateCell[], options: LcmsPlateCellsToRackOptions = {}): Rack {
|
|
85
85
|
const format = options.format ?? (options.plateType ? lcmsPlateTypeToRackFormat(options.plateType) : inferRackFormat(cells))
|
|
86
86
|
const slot = options.slot ?? cells.find(cell => cell.slot)?.slot ?? 'R'
|
|
@@ -116,7 +116,7 @@ export function lcmsPlateCellsToRack(cells: LcmsPlateCell[], options: LcmsPlateC
|
|
|
116
116
|
}
|
|
117
117
|
}
|
|
118
118
|
|
|
119
|
-
/** @deprecated Scheduled for removal in MINT 1.4;
|
|
119
|
+
/** @deprecated Scheduled for removal in MINT 1.4; no SDK replacement. */
|
|
120
120
|
export function lcmsPlateCellsToRacks(cells: LcmsPlateCell[], options: LcmsPlateCellsToRacksOptions = {}): Rack[] {
|
|
121
121
|
const bySlot = new Map<SlotPosition, LcmsPlateCell[]>()
|
|
122
122
|
const defaultSlot = options.defaultSlot ?? 'R'
|
|
@@ -138,7 +138,7 @@ export function lcmsPlateCellsToRacks(cells: LcmsPlateCell[], options: LcmsPlate
|
|
|
138
138
|
}))
|
|
139
139
|
}
|
|
140
140
|
|
|
141
|
-
/** @deprecated Scheduled for removal in MINT 1.4;
|
|
141
|
+
/** @deprecated Scheduled for removal in MINT 1.4; no SDK replacement. */
|
|
142
142
|
export function rackToLcmsPlateCells(rack: Rack): LcmsPlateCell[] {
|
|
143
143
|
return Object.entries(rack.wells)
|
|
144
144
|
.map(([wellId, well]) => wellToLcmsPlateCell(rack, wellId, well))
|
|
@@ -146,18 +146,18 @@ export function rackToLcmsPlateCells(rack: Rack): LcmsPlateCell[] {
|
|
|
146
146
|
.sort(comparePlateCells)
|
|
147
147
|
}
|
|
148
148
|
|
|
149
|
-
/** @deprecated Scheduled for removal in MINT 1.4;
|
|
149
|
+
/** @deprecated Scheduled for removal in MINT 1.4; no SDK replacement. */
|
|
150
150
|
export function racksToLcmsPlateCells(racks: Rack[]): LcmsPlateCell[] {
|
|
151
151
|
return racks.flatMap(rackToLcmsPlateCells)
|
|
152
152
|
}
|
|
153
153
|
|
|
154
|
-
/** @deprecated Scheduled for removal in MINT 1.4;
|
|
154
|
+
/** @deprecated Scheduled for removal in MINT 1.4; no SDK replacement. */
|
|
155
155
|
export function getLcmsDefaultControlWellId(plateType: LcmsPlateType, sampleType: LcmsControlSampleType): string {
|
|
156
156
|
const position = LCMS_DEFAULT_CONTROL_POSITIONS[plateType][sampleType]
|
|
157
157
|
return lcmsWellId(position.row, position.column)
|
|
158
158
|
}
|
|
159
159
|
|
|
160
|
-
/** @deprecated Scheduled for removal in MINT 1.4;
|
|
160
|
+
/** @deprecated Scheduled for removal in MINT 1.4; no SDK replacement. */
|
|
161
161
|
export function createLcmsControlWellEditData(
|
|
162
162
|
sampleType: LcmsControlSampleType,
|
|
163
163
|
options: {
|