@gen-epix/ui-client-casedb 4.0.2 → 4.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.
Files changed (69) hide show
  1. package/dist/_chunks/AddCasesToEventDialog.js +98 -98
  2. package/dist/_chunks/AddCasesToEventDialog.js.map +1 -1
  3. package/dist/_chunks/CaseContentForm.js +10 -10
  4. package/dist/_chunks/CaseDbDownloadUtil.js +1 -1
  5. package/dist/_chunks/CaseDbDownloadUtil.js.map +1 -1
  6. package/dist/_chunks/CaseInfoDialog.js +222 -222
  7. package/dist/_chunks/CaseInfoDialog.js.map +1 -1
  8. package/dist/_chunks/CaseSetInfoDialog.js +222 -222
  9. package/dist/_chunks/CaseSetInfoDialog.js.map +1 -1
  10. package/dist/_chunks/CasesAlreadyInCaseSetWarning.js.map +1 -1
  11. package/dist/_chunks/Dashboard.js +296 -295
  12. package/dist/_chunks/Dashboard.js.map +1 -1
  13. package/dist/_chunks/FindSimilarCasesDialog.js +81 -81
  14. package/dist/_chunks/FindSimilarCasesDialog.js.map +1 -1
  15. package/dist/_chunks/HomePageTrends.js.map +1 -1
  16. package/dist/_chunks/LegendaItem.js.map +1 -1
  17. package/dist/_chunks/LineListWidget.js +46 -45
  18. package/dist/_chunks/LineListWidget.js.map +1 -1
  19. package/dist/_chunks/PanelSeparator.js +3 -3
  20. package/dist/_chunks/PanelSeparator.js.map +1 -1
  21. package/dist/_chunks/Upload.js +422 -418
  22. package/dist/_chunks/Upload.js.map +1 -1
  23. package/dist/_chunks/UploadUtil.js +44 -40
  24. package/dist/_chunks/UploadUtil.js.map +1 -1
  25. package/dist/_chunks/chunk-BV7QT456.js +1 -1
  26. package/dist/_chunks/chunk-BV7QT456.js.map +1 -1
  27. package/dist/_chunks/cloneDeep.js +1 -1
  28. package/dist/_chunks/cloneDeep.js.map +1 -1
  29. package/dist/_chunks/dashboardStore.js.map +1 -1
  30. package/dist/_chunks/esm.js +3 -3
  31. package/dist/_chunks/esm.js.map +1 -1
  32. package/dist/_chunks/index.module.js +1 -1
  33. package/dist/_chunks/index.module.js.map +1 -1
  34. package/dist/_chunks/react.js +1 -1
  35. package/dist/_chunks/react.js.map +1 -1
  36. package/dist/_chunks/shallow.js +2 -2
  37. package/dist/_chunks/shallow.js.map +1 -1
  38. package/dist/_chunks/vanilla.js +1 -1
  39. package/dist/_chunks/vanilla.js.map +1 -1
  40. package/dist/_chunks/yup.js +24 -24
  41. package/dist/_chunks/yup.js.map +1 -1
  42. package/dist/classes/services/EventBusService/EventBusService.d.ts +9 -2
  43. package/dist/classes/services/EventBusService/index.js.map +1 -1
  44. package/dist/components/form/fields/ArrangementEditor/index.js +30 -30
  45. package/dist/components/ui/CreateEventDialog/index.js +40 -40
  46. package/dist/components/ui/CreateEventDialog/index.js.map +1 -1
  47. package/dist/components/ui/MapWidget/index.js.map +1 -1
  48. package/dist/components/ui/RemoveCasesFromEventDialog/index.js.map +1 -1
  49. package/dist/components/ui/SequenceDownloadDialog/index.js +57 -44
  50. package/dist/components/ui/SequenceDownloadDialog/index.js.map +1 -1
  51. package/dist/components/ui/TreeWidget/index.js +8 -2
  52. package/dist/components/ui/TreeWidget/index.js.map +1 -1
  53. package/dist/locale/en.json +0 -11
  54. package/dist/locale/nl.json +0 -11
  55. package/dist/models/config.d.ts +2 -0
  56. package/dist/pages/UserEffectiveRightsTesterAdminPage/index.js +59 -59
  57. package/dist/pages/UserEffectiveRightsTesterAdminPage/index.js.map +1 -1
  58. package/dist/utils/UploadUtil/UploadUtil.d.ts +1 -0
  59. package/package.json +68 -75
  60. package/dist/_chunks/index.esm.js +0 -1465
  61. package/dist/_chunks/index.esm.js.map +0 -1
  62. package/dist/components/ui/FileSelector/FileSelector.d.ts +0 -7
  63. package/dist/components/ui/FileSelector/index.d.ts +0 -1
  64. package/dist/components/ui/FileSelector/index.js +0 -206
  65. package/dist/components/ui/FileSelector/index.js.map +0 -1
  66. package/dist/utils/FileUtil/FileUtil.d.ts +0 -5
  67. package/dist/utils/FileUtil/index.d.ts +0 -1
  68. package/dist/utils/FileUtil/index.js +0 -15
  69. package/dist/utils/FileUtil/index.js.map +0 -1
@@ -10,55 +10,55 @@ import { t as u } from "./CompletCaseTypeLoader.js";
10
10
  import { t as d } from "./shallow.js";
11
11
  import { UPLOAD_STEP as f } from "../models/upload.js";
12
12
  import { UploadStoreContext as p } from "../stores/uploadStore/index.js";
13
- import { c as m, o as h } from "./index.esm.js";
14
- import { t as g } from "./yup.js";
15
- import { useCaseTypeOptionsQuery as _, useCaseTypesQuery as v } from "../dataHooks/useCaseTypesQuery/index.js";
16
- import { useDataCollectionOptionsQuery as y } from "../dataHooks/useDataCollectionsQuery/index.js";
17
- import { useColMapQuery as b, useColsQuery as x } from "../dataHooks/useColsQuery/index.js";
18
- import { CaseContentFormDialog as S } from "../components/ui/CaseContentFormDialog/index.js";
19
- import { FileSelector as C } from "../components/ui/FileSelector/index.js";
20
- import { useSequencingProtocolOptionsQuery as w } from "../dataHooks/useSequencingProtocolsQuery/index.js";
21
- import { useAssemblyProtocolOptionsQuery as T } from "../dataHooks/useAssemblyProtocolsQuery/index.js";
22
- import { mixed as E, object as D, string as O } from "yup";
23
- import { CaseDbCaseApi as k, CaseDbDataIssueType as A, CaseDbEtlStatus as j, CaseDbUploadAction as M } from "@gen-epix/api-casedb";
13
+ import { t as m } from "./yup.js";
14
+ import { useCaseTypeOptionsQuery as h, useCaseTypesQuery as g } from "../dataHooks/useCaseTypesQuery/index.js";
15
+ import { useDataCollectionOptionsQuery as _ } from "../dataHooks/useDataCollectionsQuery/index.js";
16
+ import { useColMapQuery as v, useColsQuery as y } from "../dataHooks/useColsQuery/index.js";
17
+ import { CaseContentFormDialog as b } from "../components/ui/CaseContentFormDialog/index.js";
18
+ import { useSequencingProtocolOptionsQuery as x } from "../dataHooks/useSequencingProtocolsQuery/index.js";
19
+ import { useAssemblyProtocolOptionsQuery as S } from "../dataHooks/useAssemblyProtocolsQuery/index.js";
20
+ import { mixed as C, object as w, string as T } from "yup";
21
+ import { CaseDbCaseApi as E, CaseDbDataIssueType as D, CaseDbEtlStatus as O, CaseDbUploadAction as k } from "@gen-epix/api-casedb";
24
22
  import { QueryClientService as ee } from "@gen-epix/ui-client-common/classes/services/QueryClientService";
25
- import { ObjectUtil as N } from "@gen-epix/ui-core/utils/ObjectUtil";
26
- import { FORM_FIELD_DEFINITION_TYPE as P } from "@gen-epix/ui-core-form/models/form";
27
- import { ConfigService as te } from "@gen-epix/ui-client-common/classes/services/ConfigService";
28
- import { Alert as F, AlertTitle as I, Autocomplete as ne, Box as L, Button as R, Container as re, ListItemIcon as z, ListItemText as B, MenuItem as ie, Table as V, TableBody as H, TableCell as U, TableHead as ae, TableRow as oe, TextField as se, Tooltip as ce, Typography as le, useTheme as ue } from "@mui/material";
29
- import { use as W, useCallback as G, useEffect as K, useId as de, useMemo as q, useRef as J, useState as Y } from "react";
23
+ import { ObjectUtil as A } from "@gen-epix/ui-core/utils/ObjectUtil";
24
+ import { FORM_FIELD_DEFINITION_TYPE as j } from "@gen-epix/ui-core-form/models/form";
25
+ import { ConfigService as M } from "@gen-epix/ui-client-common/classes/services/ConfigService";
26
+ import { Alert as N, AlertTitle as P, Autocomplete as F, Box as I, Button as L, Container as te, ListItemIcon as ne, ListItemText as R, MenuItem as z, Table as B, TableBody as V, TableCell as H, TableHead as U, TableRow as re, TextField as ie, Tooltip as ae, Typography as oe, useTheme as se } from "@mui/material";
27
+ import { use as W, useCallback as G, useEffect as K, useId as ce, useMemo as q, useRef as J, useState as Y } from "react";
30
28
  import { useTranslation as X } from "react-i18next";
31
- import { TableStoreContextProvider as fe, createTableStore as pe, useTableStoreContext as me } from "@gen-epix/ui-client-common/stores/tableStore";
29
+ import { TableStoreContextProvider as le, createTableStore as ue, useTableStoreContext as de } from "@gen-epix/ui-client-common/stores/tableStore";
32
30
  import { Fragment as Z, jsx as Q, jsxs as $ } from "react/jsx-runtime";
33
- import { ResponseHandler as he } from "@gen-epix/ui-client-common/components/ui/ResponseHandler";
34
- import { useItemQuery as ge } from "@gen-epix/ui-client-common/hooks/useItemQuery";
35
- import { useArray as _e } from "@gen-epix/ui-core/hooks/useArray";
36
- import ve from "@mui/material/Box";
37
- import { Stepper as ye } from "@gen-epix/ui-core-components/components/Stepper";
38
- import { GenericForm as be } from "@gen-epix/ui-core-form/components/helpers/GenericForm";
39
- import { useQueryMemo as xe } from "@gen-epix/ui-client-common/hooks/useQueryMemo";
40
- import { useIdentifierIssuerOwnOrganizationOptionsQuery as Se } from "@gen-epix/ui-client-common/dataHooks/useIdentifierIssuerOwnOrganizationQuery";
41
- import { Select as Ce } from "@gen-epix/ui-core-form/components/fields/Select";
42
- import { BackdropSpinner as we } from "@gen-epix/ui-core-components/components/BackdropSpinner";
43
- import { Confirmation as Te } from "@gen-epix/ui-core-components/components/Confirmation";
44
- import Ee from "@mui/icons-material/Edit";
45
- import De from "@mui/icons-material/ErrorOutlined";
46
- import Oe from "@mui/icons-material/Add";
47
- import { Table as ke, TableMenu as Ae } from "@gen-epix/ui-client-common/components/ui/Table";
48
- import { TABLE_COLUMN_FROZEN as je } from "@gen-epix/ui-client-common/models/table";
49
- import { TableUtil as Me } from "@gen-epix/ui-client-common/utils/TableUtil";
50
- import { useInitializeTableStore as Ne } from "@gen-epix/ui-client-common/hooks/useInitializeTableStore";
51
- import { withDialog as Pe } from "@gen-epix/ui-core-components/hoc/withDialog";
52
- import { TestIdUtil as Fe } from "@gen-epix/ui-core/utils/TestIdUtil";
53
- import { FormUtil as Ie } from "@gen-epix/ui-core-form/utils/FormUtil";
54
- import { GenericErrorMessage as Le } from "@gen-epix/ui-client-common/components/ui/GenericErrorMessage";
55
- import { InactivityService as Re } from "@gen-epix/ui-client-common/classes/services/InactivityService";
56
- import { LinearProgressWithLabel as ze } from "@gen-epix/ui-core-components/components/LinearProgressWithLabel";
57
- import { RouterService as Be } from "@gen-epix/ui-client-common/classes/services/RouterService";
31
+ import { ResponseHandler as fe } from "@gen-epix/ui-client-common/components/ui/ResponseHandler";
32
+ import { useItemQuery as pe } from "@gen-epix/ui-client-common/hooks/useItemQuery";
33
+ import { useArray as me } from "@gen-epix/ui-core/hooks/useArray";
34
+ import he from "@mui/material/Box";
35
+ import { Stepper as ge } from "@gen-epix/ui-core-components/components/Stepper";
36
+ import { useForm as _e, useWatch as ve } from "react-hook-form";
37
+ import { GenericForm as ye } from "@gen-epix/ui-core-form/components/helpers/GenericForm";
38
+ import { useQueryMemo as be } from "@gen-epix/ui-client-common/hooks/useQueryMemo";
39
+ import { useIdentifierIssuerOwnOrganizationOptionsQuery as xe } from "@gen-epix/ui-client-common/dataHooks/useIdentifierIssuerOwnOrganizationQuery";
40
+ import { Select as Se } from "@gen-epix/ui-core-form/components/fields/Select";
41
+ import { BackdropSpinner as Ce } from "@gen-epix/ui-core-components/components/BackdropSpinner";
42
+ import { Confirmation as we } from "@gen-epix/ui-core-components/components/Confirmation";
43
+ import Te from "@mui/icons-material/Edit";
44
+ import Ee from "@mui/icons-material/ErrorOutlined";
45
+ import De from "@mui/icons-material/Add";
46
+ import { Table as Oe, TableMenu as ke } from "@gen-epix/ui-client-common/components/ui/Table";
47
+ import { TABLE_COLUMN_FROZEN as Ae } from "@gen-epix/ui-client-common/models/table";
48
+ import { TableUtil as je } from "@gen-epix/ui-client-common/utils/TableUtil";
49
+ import { useInitializeTableStore as Me } from "@gen-epix/ui-client-common/hooks/useInitializeTableStore";
50
+ import { withDialog as Ne } from "@gen-epix/ui-core-components/hoc/withDialog";
51
+ import { TestIdUtil as Pe } from "@gen-epix/ui-core/utils/TestIdUtil";
52
+ import { FormUtil as Fe } from "@gen-epix/ui-core-form/utils/FormUtil";
53
+ import { GenericErrorMessage as Ie } from "@gen-epix/ui-client-common/components/ui/GenericErrorMessage";
54
+ import { InactivityService as Le } from "@gen-epix/ui-client-common/classes/services/InactivityService";
55
+ import { LinearProgressWithLabel as Re } from "@gen-epix/ui-core-components/components/LinearProgressWithLabel";
56
+ import { RouterService as ze } from "@gen-epix/ui-client-common/classes/services/RouterService";
57
+ import { MultiFileUploader as Be } from "@gen-epix/ui-core-components/components/MultiFileUploader";
58
58
  //#region src/components/ui/Upload/UploadNavigation.tsx
59
59
  var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proceedDisabled: r, proceedLabel: i }) => {
60
60
  let { t: a } = X(), o = W(p), s = l(o, (e) => e.stepOrder), c = l(o, (e) => e.activeStep), u = l(o, (e) => e.goBackFromFirstStepCallback), d = l(o, (e) => e.goBackFromFirstStepLabel), f = c === s[0], m = f ? u ?? t : t;
61
- return /* @__PURE__ */ $(L, {
61
+ return /* @__PURE__ */ $(I, {
62
62
  sx: {
63
63
  borderTop: (e) => `1px solid ${e.palette.divider}`,
64
64
  display: "flex",
@@ -67,11 +67,11 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
67
67
  marginTop: 1,
68
68
  paddingTop: 1
69
69
  },
70
- children: [m && /* @__PURE__ */ Q(R, {
70
+ children: [m && /* @__PURE__ */ Q(L, {
71
71
  onClick: m,
72
72
  variant: "outlined",
73
73
  children: (f ? d ?? e : e) ?? a`Go back`
74
- }), n && /* @__PURE__ */ Q(R, {
74
+ }), n && /* @__PURE__ */ Q(L, {
75
75
  color: "secondary",
76
76
  disabled: r,
77
77
  onClick: n,
@@ -80,66 +80,70 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
80
80
  })]
81
81
  });
82
82
  }, He = () => {
83
- let { t: e } = X(), n = v(), r = _(), a = y(), o = x(), s = de(), c = W(p), u = l(c, (e) => e.caseTypeId), d = l(c, (e) => e.fileList), f = l(c, (e) => e.fileName), m = l(c, (e) => e.fileParsingError), b = l(c, (e) => e.goToNextStep), S = l(c, (e) => e.createdInDataCollectionOptions), C = l(c, (e) => e.rawData), w = l(c, (e) => e.setCols), T = l(c, (e) => e.setCaseTypeId), A = l(c, (e) => e.setCompleteCaseType), j = l(c, (e) => e.setCreatedInDataCollectionId), M = l(c, (e) => e.setFileList), ee = l(c, (e) => e.setSheet), N = l(c, (e) => e.setDataCollectionOptions), te = l(c, (e) => e.sheet), ne = l(c, (e) => e.sheetOptions), L = q(() => D().shape({
84
- caseTypeId: O().uuid4().required(),
85
- createdInDataCollectionId: O().uuid4().required(),
86
- fileList: E().required(e`File is required`),
87
- sheet: O().required(e`Sheet is required`)
88
- }), [e]), R = h({
83
+ let { t: e } = X(), n = g(), r = h(), a = _(), o = y(), s = ce(), c = W(p), u = l(c, (e) => e.caseTypeId), d = l(c, (e) => e.fileList), f = l(c, (e) => e.fileName), v = l(c, (e) => e.fileParsingError), b = l(c, (e) => e.goToNextStep), x = l(c, (e) => e.createdInDataCollectionOptions), S = l(c, (e) => e.rawData), D = l(c, (e) => e.setCols), O = l(c, (e) => e.setCaseTypeId), k = l(c, (e) => e.setCompleteCaseType), ee = l(c, (e) => e.setCreatedInDataCollectionId), A = l(c, (e) => e.setFileList), M = l(c, (e) => e.setSheet), F = l(c, (e) => e.setDataCollectionOptions), I = l(c, (e) => e.sheet), L = l(c, (e) => e.sheetOptions), ne = q(() => w().shape({
84
+ caseTypeId: T().uuid4().required(),
85
+ createdInDataCollectionId: T().uuid4().required(),
86
+ fileList: C().required(e`File is required`),
87
+ sheet: T().when("fileList", {
88
+ is: t.isXlsxFile(f),
89
+ otherwise: (e) => e.notRequired(),
90
+ then: (t) => t.required(e`Sheet is required`)
91
+ })
92
+ }), [f, e]), R = _e({
89
93
  defaultValues: {
90
94
  caseTypeId: null,
91
95
  createdInDataCollectionId: null,
92
96
  fileList: null,
93
97
  sheet: null
94
98
  },
95
- resolver: g(L),
99
+ resolver: m(ne),
96
100
  values: {
97
101
  caseTypeId: c.getState().caseTypeId ?? null,
98
102
  createdInDataCollectionId: c.getState().createdInDataCollectionId ?? null,
99
103
  fileList: c.getState().fileList ?? null,
100
104
  sheet: c.getState().sheet ?? null
101
105
  }
102
- }), { handleSubmit: z, setError: B, setValue: ie } = R;
106
+ }), { handleSubmit: z, setError: B, setValue: V } = R;
103
107
  K(() => {
104
- Array.isArray(o?.data) && w(o.data);
105
- }, [o.data, w]), K(() => {
106
- a?.options?.length && N(a.options);
107
- }, [a?.options, N]);
108
- let { data: V, error: H, isLoading: U } = ge({
108
+ Array.isArray(o?.data) && D(o.data);
109
+ }, [o.data, D]), K(() => {
110
+ a?.options?.length && F(a.options);
111
+ }, [a?.options, F]);
112
+ let { data: H, error: U, isLoading: re } = pe({
109
113
  baseQueryKey: i.COMPLETE_CASE_TYPES,
110
114
  itemId: u,
111
115
  useQueryOptions: {
112
116
  enabled: !!u,
113
- queryFn: async ({ signal: e }) => (await k.getInstance().completeCaseTypesGetOne(u, { signal: e })).data
117
+ queryFn: async ({ signal: e }) => (await E.getInstance().completeCaseTypesGetOne(u, { signal: e })).data
114
118
  }
115
119
  });
116
120
  K(() => {
117
- V && A(V);
118
- }, [V, A]);
119
- let ae = G(async (e) => {
121
+ H && k(H);
122
+ }, [H, k]);
123
+ let ie = G(async (e) => {
124
+ await A(e);
125
+ }, [A]), ae = G(async (e) => {
120
126
  await M(e);
121
- }, [M]), oe = G(async (e) => {
122
- await ee(e);
123
- }, [ee]), se = G((e) => {
124
- T(e);
125
- }, [T]), ce = G((e) => {
126
- j(e);
127
- }, [j]), ue = q(() => {
127
+ }, [M]), se = G((e) => {
128
+ O(e);
129
+ }, [O]), J = G((e) => {
130
+ ee(e);
131
+ }, [ee]), Y = q(() => {
128
132
  let n = [{
129
133
  accept: ".csv,.tsv,.txt,.xlsx",
130
- definition: P.FILE,
134
+ definition: j.FILE,
131
135
  label: e`File`,
132
136
  name: "fileList",
133
- onChange: ae
137
+ onChange: ie
134
138
  }];
135
139
  return t.isXlsxFile(f) && n.push({
136
- definition: P.SELECT,
140
+ definition: j.SELECT,
137
141
  label: e`Sheet`,
138
142
  name: "sheet",
139
- onChange: oe,
140
- options: ne
143
+ onChange: ae,
144
+ options: L
141
145
  }), n.push({
142
- definition: P.AUTOCOMPLETE,
146
+ definition: j.AUTOCOMPLETE,
143
147
  disabled: !d,
144
148
  label: e`Case type`,
145
149
  loading: r.isLoading,
@@ -147,50 +151,50 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
147
151
  onChange: se,
148
152
  options: r.options
149
153
  }, {
150
- definition: P.SELECT,
154
+ definition: j.SELECT,
151
155
  disabled: !d || !u,
152
156
  label: e`Create in data collection`,
153
- loading: a.isLoading || U,
157
+ loading: a.isLoading || re,
154
158
  name: "createdInDataCollectionId",
155
- onChange: ce,
156
- options: S
159
+ onChange: J,
160
+ options: x
157
161
  }), n;
158
162
  }, [
159
163
  e,
160
- ae,
164
+ ie,
161
165
  f,
162
166
  r.options,
163
167
  r.isLoading,
164
168
  d,
165
169
  se,
166
- S,
170
+ x,
167
171
  a.isLoading,
168
- U,
172
+ re,
169
173
  u,
170
- ce,
171
- ne,
172
- oe
174
+ J,
175
+ L,
176
+ ae
173
177
  ]);
174
178
  K(() => {
175
- m ? B("fileList", {
176
- message: m,
179
+ v ? B("fileList", {
180
+ message: v,
177
181
  type: "manual"
178
182
  }) : B("fileList", void 0);
179
183
  }, [
180
- m,
184
+ v,
181
185
  B,
182
- ie
186
+ V
183
187
  ]);
184
- let J = G(async () => {
188
+ let le = G(async () => {
185
189
  await b();
186
- }, [b]), Y = _e([
190
+ }, [b]), ue = me([
187
191
  n,
188
192
  r,
189
193
  a,
190
194
  o
191
- ]), fe = G(async () => {
192
- await z(J)();
193
- }, [z, J]), pe = q(() => !(o.isLoading === !1 && o.data?.length === 0 || r.isLoading === !1 && r.options?.length === 0 || a.isLoading === !1 && a.options?.length === 0), [
195
+ ]), de = G(async () => {
196
+ await z(le)();
197
+ }, [z, le]), he = q(() => !(o.isLoading === !1 && o.data?.length === 0 || r.isLoading === !1 && r.options?.length === 0 || a.isLoading === !1 && a.options?.length === 0), [
194
198
  o.data?.length,
195
199
  o.isLoading,
196
200
  r.isLoading,
@@ -198,69 +202,69 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
198
202
  a.isLoading,
199
203
  a.options?.length
200
204
  ]);
201
- return /* @__PURE__ */ Q(he, {
202
- error: H,
205
+ return /* @__PURE__ */ Q(fe, {
206
+ error: U,
203
207
  inlineSpinner: !0,
204
- loadables: Y,
205
- children: /* @__PURE__ */ $(re, {
208
+ loadables: ue,
209
+ children: /* @__PURE__ */ $(te, {
206
210
  maxWidth: "lg",
207
- children: [!pe && /* @__PURE__ */ Q(F, {
211
+ children: [!he && /* @__PURE__ */ Q(N, {
208
212
  severity: "warning",
209
213
  sx: { mb: 2 },
210
214
  children: e("Upload is disabled because you have insufficient data access to proceed. Contact your organization administrator for assistance.")
211
- }), pe && /* @__PURE__ */ $(Z, { children: [
212
- C && C.length > 0 && /* @__PURE__ */ $(F, {
215
+ }), he && /* @__PURE__ */ $(Z, { children: [
216
+ S && S.length > 0 && /* @__PURE__ */ $(N, {
213
217
  severity: "info",
214
218
  sx: { mb: 2 },
215
219
  children: [
216
- /* @__PURE__ */ Q(I, { children: e("{{fileName}} loaded successfully", { fileName: f }) }),
217
- te && /* @__PURE__ */ Q(le, { children: e("Sheet name: {{sheet}}", { sheet: te || "" }) }),
218
- /* @__PURE__ */ Q(le, { children: e("Number of columns: {{columnCount}}", { columnCount: C[0].length }) }),
219
- /* @__PURE__ */ Q(le, { children: e("Number of data rows: {{rowCount}}", { rowCount: C.length - 1 }) })
220
+ /* @__PURE__ */ Q(P, { children: e("{{fileName}} loaded successfully", { fileName: f }) }),
221
+ I && /* @__PURE__ */ Q(oe, { children: e("Sheet name: {{sheet}}", { sheet: I || "" }) }),
222
+ /* @__PURE__ */ Q(oe, { children: e("Number of columns: {{columnCount}}", { columnCount: S[0].length }) }),
223
+ /* @__PURE__ */ Q(oe, { children: e("Number of data rows: {{rowCount}}", { rowCount: S.length - 1 }) })
220
224
  ]
221
225
  }),
222
- /* @__PURE__ */ Q(be, {
223
- formFieldDefinitions: ue,
226
+ /* @__PURE__ */ Q(ye, {
227
+ formFieldDefinitions: Y,
224
228
  formId: s,
225
229
  formMethods: R,
226
- onSubmit: z(J),
227
- schema: L
230
+ onSubmit: z(le),
231
+ schema: ne
228
232
  }),
229
- /* @__PURE__ */ Q(Ve, { onProceedButtonClick: fe })
233
+ /* @__PURE__ */ Q(Ve, { onProceedButtonClick: de })
230
234
  ] })]
231
235
  })
232
236
  });
233
237
  }, Ue = /* @__PURE__ */ e(r(), 1), We = /* @__PURE__ */ e(o(), 1), Ge = () => {
234
- let { t: e } = X(), n = b(), r = Se(), i = W(p), a = l(i, (e) => e.completeCaseType), o = l(i, (e) => e.rawData), s = l(i, (e) => e.fileName), c = l(i, (e) => e.goToNextStep), u = l(i, (e) => e.goToPreviousStep), d = l(i, (e) => e.setMappedColumns), f = _e([n, r]), _ = de(), v = q(() => t.getColumnMappingSchema(o, a), [a, o]), y = q(() => t.getDefaultColumnMappingFormValues(o[0], i.getState().mappedColumns, r.options), [
238
+ let { t: e } = X(), n = v(), r = xe(), i = W(p), a = l(i, (e) => e.completeCaseType), o = l(i, (e) => e.rawData), s = l(i, (e) => e.fileName), c = l(i, (e) => e.goToNextStep), u = l(i, (e) => e.goToPreviousStep), d = l(i, (e) => e.setMappedColumns), f = me([n, r]), h = ce(), g = q(() => t.getColumnMappingSchema(o, a), [a, o]), _ = q(() => t.getDefaultColumnMappingFormValues(o[0], i.getState().mappedColumns, r.options), [
235
239
  o,
236
240
  i,
237
241
  r.options
238
- ]), x = h({
239
- defaultValues: { ...y },
240
- resolver: g(v),
241
- values: { ...y }
242
- }), { clearErrors: S, control: C, handleSubmit: w } = x, T = m({ control: C }), E = q(() => t.getColumnMappingFormFieldDefinitions(a, o[0], s).map((e) => ({
242
+ ]), y = _e({
243
+ defaultValues: { ..._ },
244
+ resolver: m(g),
245
+ values: { ..._ }
246
+ }), { clearErrors: b, control: x, handleSubmit: S } = y, C = ve({ control: x }), w = q(() => t.getColumnMappingFormFieldDefinitions(a, o[0], s).map((e) => ({
243
247
  ...e,
244
- onChange: () => S()
248
+ onChange: () => b()
245
249
  })), [
246
250
  a,
247
251
  o,
248
252
  s,
249
- S
253
+ b
250
254
  ]);
251
255
  K(() => {
252
256
  (async () => {
253
- await d(t.getMappedColumnsFromFormData(T, o, n.map, a));
257
+ await d(t.getMappedColumnsFromFormData(C, o, n.map, a));
254
258
  })();
255
259
  }, [
256
260
  d,
257
- T,
261
+ C,
258
262
  o,
259
263
  n.map,
260
264
  a
261
265
  ]);
262
- let D = q(() => {
263
- let e = o[0].map((e, t) => t), r = t.getMappedColumnsFromFormData(T, o, n.map, a).map((e) => e.originalIndex);
266
+ let T = q(() => {
267
+ let e = o[0].map((e, t) => t), r = t.getMappedColumnsFromFormData(C, o, n.map, a).map((e) => e.originalIndex);
264
268
  return (0, We.default)(e, r).map((e) => ({
265
269
  originalIndex: e,
266
270
  originalLabel: o[0][e]
@@ -268,9 +272,9 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
268
272
  }, [
269
273
  n.map,
270
274
  o,
271
- T,
275
+ C,
272
276
  a
273
- ]), O = G(async (e) => {
277
+ ]), E = G(async (e) => {
274
278
  await d(t.getMappedColumnsFromFormData(e, o, n.map, a)), await c();
275
279
  }, [
276
280
  o,
@@ -278,93 +282,93 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
278
282
  c,
279
283
  d,
280
284
  a
281
- ]), k = q(() => t.getSampleIdColIds(a), [a]), A = G((t, n) => {
282
- let i = parseInt(t.name, 10), a = (0, Ue.default)(o.slice(1).map((e) => e[i] ?? "")).filter((e) => !!e).slice(0, 5).join(", ").trim() || e("<no data>"), s = n, c = T[t.name];
283
- return k.includes(c) && (s = /* @__PURE__ */ $(Z, { children: [/* @__PURE__ */ Q(L, { children: n }), /* @__PURE__ */ Q(L, {
285
+ ]), D = q(() => t.getSampleIdColIds(a), [a]), O = G((t, n) => {
286
+ let i = parseInt(t.name, 10), a = (0, Ue.default)(o.slice(1).map((e) => e[i] ?? "")).filter((e) => !!e).slice(0, 5).join(", ").trim() || e("<no data>"), s = n, c = C[t.name];
287
+ return D.includes(c) && (s = /* @__PURE__ */ $(Z, { children: [/* @__PURE__ */ Q(I, { children: n }), /* @__PURE__ */ Q(I, {
284
288
  sx: { marginTop: 1 },
285
- children: /* @__PURE__ */ Q(Ce, {
289
+ children: /* @__PURE__ */ Q(Se, {
286
290
  label: e("{{columnLabel}}: Identifier issuer", { columnLabel: t.label }),
287
291
  loading: r.isLoading,
288
292
  name: c,
289
293
  options: r.options
290
294
  })
291
- })] })), /* @__PURE__ */ $(oe, { children: [
292
- /* @__PURE__ */ Q(U, { children: t.label }),
293
- /* @__PURE__ */ Q(U, { children: s }),
294
- /* @__PURE__ */ Q(U, { children: a })
295
+ })] })), /* @__PURE__ */ $(re, { children: [
296
+ /* @__PURE__ */ Q(H, { children: t.label }),
297
+ /* @__PURE__ */ Q(H, { children: s }),
298
+ /* @__PURE__ */ Q(H, { children: a })
295
299
  ] }, t.name);
296
300
  }, [
297
- T,
301
+ C,
298
302
  r.isLoading,
299
303
  r.options,
300
304
  o,
301
- k,
305
+ D,
302
306
  e
303
- ]), j = G((t) => /* @__PURE__ */ $(V, {
307
+ ]), k = G((t) => /* @__PURE__ */ $(B, {
304
308
  size: "small",
305
- children: [/* @__PURE__ */ Q(ae, {
309
+ children: [/* @__PURE__ */ Q(U, {
306
310
  sx: {
307
311
  backgroundColor: (e) => e.palette.background.paper,
308
312
  position: "sticky",
309
313
  top: 0,
310
314
  zIndex: (e) => e.zIndex.appBar - 1
311
315
  },
312
- children: /* @__PURE__ */ $(oe, { children: [
313
- /* @__PURE__ */ Q(U, {
316
+ children: /* @__PURE__ */ $(re, { children: [
317
+ /* @__PURE__ */ Q(H, {
314
318
  sx: { width: "33%" },
315
319
  children: e`Source`
316
320
  }),
317
- /* @__PURE__ */ Q(U, {
321
+ /* @__PURE__ */ Q(H, {
318
322
  sx: { width: "33%" },
319
- children: te.getInstance().config.applicationName
323
+ children: M.getInstance().config.applicationName
320
324
  }),
321
- /* @__PURE__ */ Q(U, {
325
+ /* @__PURE__ */ Q(H, {
322
326
  sx: { width: "34%" },
323
327
  children: e`Data preview (first 5 unique values)`
324
328
  })
325
329
  ] })
326
- }), /* @__PURE__ */ Q(H, { children: t })]
327
- }), [e]), M = G(async () => {
328
- await w(O)();
329
- }, [w, O]), ee = G(() => {
330
+ }), /* @__PURE__ */ Q(V, { children: t })]
331
+ }), [e]), ee = G(async () => {
332
+ await S(E)();
333
+ }, [S, E]), A = G(() => {
330
334
  u();
331
335
  }, [u]);
332
- return /* @__PURE__ */ Q(he, {
336
+ return /* @__PURE__ */ Q(fe, {
333
337
  loadables: f,
334
- children: /* @__PURE__ */ $(L, {
338
+ children: /* @__PURE__ */ $(I, {
335
339
  sx: {
336
340
  display: "grid",
337
341
  gridTemplateRows: "max-content auto max-content",
338
342
  height: "100%"
339
343
  },
340
344
  children: [
341
- /* @__PURE__ */ Q(re, {
345
+ /* @__PURE__ */ Q(te, {
342
346
  maxWidth: "lg",
343
347
  sx: { marginBottom: 2 },
344
- children: /* @__PURE__ */ $(F, {
345
- severity: D.length === 0 ? "info" : "warning",
348
+ children: /* @__PURE__ */ $(N, {
349
+ severity: T.length === 0 ? "info" : "warning",
346
350
  children: [
347
- /* @__PURE__ */ Q(I, { children: D.length === 0 ? e("All columns in {{fileName}} have been mapped to known columns in {{applicationName}}", {
348
- applicationName: te.getInstance().config.applicationName,
351
+ /* @__PURE__ */ Q(P, { children: T.length === 0 ? e("All columns in {{fileName}} have been mapped to known columns in {{applicationName}}", {
352
+ applicationName: M.getInstance().config.applicationName,
349
353
  fileName: s
350
354
  }) : e("{{numUnmappedColumns}} column(s) in {{fileName}} are not mapped", {
351
355
  fileName: s,
352
- numUnmappedColumns: D.length
356
+ numUnmappedColumns: T.length
353
357
  }) }),
354
- D.map((t) => /* @__PURE__ */ Q(L, { children: e("The column \"{{columnName}}\" (column {{columnIndex}}) has not been mapped.", {
358
+ T.map((t) => /* @__PURE__ */ Q(I, { children: e("The column \"{{columnName}}\" (column {{columnIndex}}) has not been mapped.", {
355
359
  columnIndex: t.originalIndex + 1,
356
360
  columnName: t.originalLabel
357
361
  }) }, t.originalIndex)),
358
- D.length === 0 && e("You can proceed to the next step.")
362
+ T.length === 0 && e("You can proceed to the next step.")
359
363
  ]
360
364
  })
361
365
  }),
362
- /* @__PURE__ */ Q(L, {
366
+ /* @__PURE__ */ Q(I, {
363
367
  sx: {
364
368
  overflowY: "auto",
365
369
  position: "relative"
366
370
  },
367
- children: /* @__PURE__ */ Q(L, {
371
+ children: /* @__PURE__ */ Q(I, {
368
372
  sx: {
369
373
  bottom: 0,
370
374
  left: 0,
@@ -372,20 +376,20 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
372
376
  right: 0,
373
377
  top: 0
374
378
  },
375
- children: /* @__PURE__ */ Q(re, { children: /* @__PURE__ */ Q(be, {
376
- formFieldDefinitions: E,
377
- formId: _,
378
- formMethods: x,
379
- onSubmit: w(O),
380
- renderField: A,
381
- schema: v,
382
- wrapForm: j
379
+ children: /* @__PURE__ */ Q(te, { children: /* @__PURE__ */ Q(ye, {
380
+ formFieldDefinitions: w,
381
+ formId: h,
382
+ formMethods: y,
383
+ onSubmit: S(E),
384
+ renderField: O,
385
+ schema: g,
386
+ wrapForm: k
383
387
  }) })
384
388
  })
385
389
  }),
386
- /* @__PURE__ */ Q(L, { children: /* @__PURE__ */ Q(Ve, {
387
- onGoBackButtonClick: ee,
388
- onProceedButtonClick: M
390
+ /* @__PURE__ */ Q(I, { children: /* @__PURE__ */ Q(Ve, {
391
+ onGoBackButtonClick: A,
392
+ onProceedButtonClick: ee
389
393
  }) })
390
394
  ]
391
395
  })
@@ -399,8 +403,8 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
399
403
  onCompleteCaseTypeLoaded: i,
400
404
  children: n && /* @__PURE__ */ Q(e, { ...t })
401
405
  });
402
- }, qe = Pe(({ onActionsChange: e, onClose: t, onSubmit: n, onTitleChange: r, openProps: i }) => {
403
- let { t: a } = X(), o = de(), s = q(() => i.completeCaseType.cols[i.colId], [i.completeCaseType.cols, i.colId]);
406
+ }, qe = Ne(({ onActionsChange: e, onClose: t, onSubmit: n, onTitleChange: r, openProps: i }) => {
407
+ let { t: a } = X(), o = ce(), s = q(() => i.completeCaseType.cols[i.colId], [i.completeCaseType.cols, i.colId]);
404
408
  K(() => {
405
409
  r(a("Edit values for {{colLabel}} (for selected rows)", { colLabel: s.label }));
406
410
  }, [
@@ -411,11 +415,11 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
411
415
  let l = q(() => c.createYupSchema({
412
416
  completeCaseType: i.completeCaseType,
413
417
  includedColIds: [i.colId]
414
- }), [i.completeCaseType, i.colId]), u = h({ resolver: g(l) }), { handleSubmit: d } = u, { fieldDefinitions: f } = q(() => c.createFormDefinitions({
418
+ }), [i.completeCaseType, i.colId]), u = _e({ resolver: m(l) }), { handleSubmit: d } = u, { fieldDefinitions: f } = q(() => c.createFormDefinitions({
415
419
  completeCaseType: i.completeCaseType,
416
420
  includedColIds: [i.colId]
417
421
  }), [i.completeCaseType, i.colId]), p = G((e) => {
418
- n(Ie.createStringValuesFromFormValues(f, e)), t();
422
+ n(Fe.createStringValuesFromFormValues(f, e)), t();
419
423
  }, [
420
424
  f,
421
425
  t,
@@ -423,7 +427,7 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
423
427
  ]);
424
428
  return K(() => {
425
429
  e([{
426
- ...Fe.createAttributes("UploadEditColumnValuesDialog-submitButton"),
430
+ ...Pe.createAttributes("UploadEditColumnValuesDialog-submitButton"),
427
431
  color: "primary",
428
432
  form: o,
429
433
  label: a`Save and revalidate`,
@@ -434,13 +438,13 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
434
438
  o,
435
439
  e,
436
440
  a
437
- ]), /* @__PURE__ */ $(L, { children: [i.shouldShowRightsWarning && /* @__PURE__ */ Q(L, {
441
+ ]), /* @__PURE__ */ $(I, { children: [i.shouldShowRightsWarning && /* @__PURE__ */ Q(I, {
438
442
  sx: { marginBottom: 2 },
439
- children: /* @__PURE__ */ $(F, {
443
+ children: /* @__PURE__ */ $(N, {
440
444
  severity: "warning",
441
- children: [/* @__PURE__ */ Q(I, { children: a`You do not have the necessary rights to edit all rows in this column.` }), a`Only the cases that you have write access to for this column will be updated. Please review the changes carefully before submitting.`]
445
+ children: [/* @__PURE__ */ Q(P, { children: a`You do not have the necessary rights to edit all rows in this column.` }), a`Only the cases that you have write access to for this column will be updated. Please review the changes carefully before submitting.`]
442
446
  })
443
- }), /* @__PURE__ */ Q(be, {
447
+ }), /* @__PURE__ */ Q(ye, {
444
448
  formFieldDefinitions: f,
445
449
  formId: o,
446
450
  formMethods: u,
@@ -453,14 +457,14 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
453
457
  maxWidth: "md",
454
458
  testId: "UploadEditColumnValuesDialog"
455
459
  }), Je = ({ caseRightsColMap: e, caseUploadResults: t, completeCaseType: n, getOriginalCellValue: r, onCaseContentEditSubmit: i, onColContentEditSubmit: o, tableStore: s }) => {
456
- let c = ue(), { t: l } = X(), u = J(null), d = J(null), f = q(() => [
457
- A.UNAUTHORIZED,
458
- A.INVALID,
459
- A.CONFLICT,
460
- A.MISSING,
461
- A.DERIVED,
462
- A.TRANSFORMED
463
- ], []), p = q(() => [A.UNAUTHORIZED, A.INVALID], []), m = q(() => [A.MISSING, A.CONFLICT], []), h = G((r) => {
460
+ let c = se(), { t: l } = X(), u = J(null), d = J(null), f = q(() => [
461
+ D.UNAUTHORIZED,
462
+ D.INVALID,
463
+ D.CONFLICT,
464
+ D.MISSING,
465
+ D.DERIVED,
466
+ D.TRANSFORMED
467
+ ], []), p = q(() => [D.UNAUTHORIZED, D.INVALID], []), m = q(() => [D.MISSING, D.CONFLICT], []), h = G((r) => {
464
468
  d.current?.open({
465
469
  colId: r.column.id,
466
470
  completeCaseType: n,
@@ -493,23 +497,23 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
493
497
  }), t;
494
498
  }, [n.cols]), y = G((e) => {
495
499
  let t = v(e);
496
- return /* @__PURE__ */ Q(Z, { children: t.map(({ key: e, message: t }, n) => /* @__PURE__ */ Q(L, {
500
+ return /* @__PURE__ */ Q(Z, { children: t.map(({ key: e, message: t }, n) => /* @__PURE__ */ Q(I, {
497
501
  sx: { marginTop: +(n > 0) },
498
502
  children: t
499
503
  }, e)) });
500
- }, [v]), b = G((e) => v(e).map((e) => e.message).join(", "), [v]), x = G((e, t, n) => t.filter((t) => !(t.col_id !== e || t.data_issue_type === A.TRANSFORMED && t.original_value === n)).sort((e, t) => f.indexOf(e.data_issue_type) - f.indexOf(t.data_issue_type)), [f]), C = G(() => /* @__PURE__ */ Q(ce, {
504
+ }, [v]), x = G((e) => v(e).map((e) => e.message).join(", "), [v]), S = G((e, t, n) => t.filter((t) => !(t.col_id !== e || t.data_issue_type === D.TRANSFORMED && t.original_value === n)).sort((e, t) => f.indexOf(e.data_issue_type) - f.indexOf(t.data_issue_type)), [f]), C = G(() => /* @__PURE__ */ Q(ae, {
501
505
  "aria-hidden": !1,
502
506
  arrow: !0,
503
507
  title: l("Indicates if there are any issues with the case"),
504
- children: /* @__PURE__ */ Q(De, { fontSize: "small" })
508
+ children: /* @__PURE__ */ Q(Ee, { fontSize: "small" })
505
509
  }), [l]), w = G(({ row: e }) => {
506
- let t = e.data_issues.filter((e) => e.data_issue_type === A.INVALID || e.data_issue_type === A.UNAUTHORIZED);
507
- if (t.length > 0) return /* @__PURE__ */ Q(ce, {
510
+ let t = e.data_issues.filter((e) => e.data_issue_type === D.INVALID || e.data_issue_type === D.UNAUTHORIZED);
511
+ if (t.length > 0) return /* @__PURE__ */ Q(ae, {
508
512
  "aria-hidden": !1,
509
- "aria-label": b(t),
513
+ "aria-label": x(t),
510
514
  arrow: !0,
511
515
  title: y(t),
512
- children: /* @__PURE__ */ Q(De, {
516
+ children: /* @__PURE__ */ Q(Ee, {
513
517
  fontSize: "small",
514
518
  sx: {
515
519
  color: c.palette.error.main,
@@ -519,14 +523,14 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
519
523
  });
520
524
  }, [
521
525
  y,
522
- b,
526
+ x,
523
527
  c.palette.error.main
524
- ]), T = G(() => /* @__PURE__ */ Q(ce, {
528
+ ]), T = G(() => /* @__PURE__ */ Q(ae, {
525
529
  "aria-hidden": !1,
526
530
  arrow: !0,
527
531
  title: l("Indicates if case is new (will be created)"),
528
- children: /* @__PURE__ */ Q(Oe, { fontSize: "small" })
529
- }), [l]), E = G(({ row: e }) => e.id ? null : /* @__PURE__ */ Q(Oe, {
532
+ children: /* @__PURE__ */ Q(De, { fontSize: "small" })
533
+ }), [l]), E = G(({ row: e }) => e.id ? null : /* @__PURE__ */ Q(De, {
530
534
  "aria-hidden": !1,
531
535
  "aria-label": l`This case does not have an ID and will be created`,
532
536
  fontSize: "small",
@@ -534,18 +538,18 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
534
538
  marginTop: "5px",
535
539
  position: "absolute"
536
540
  }
537
- }), [l]), D = G(({ id: e, row: t }) => {
538
- let r = a.getRowValue(t.validated_content, n.cols[e], n).long, i = x(e, t.data_issues, r);
541
+ }), [l]), O = G(({ id: e, row: t }) => {
542
+ let r = a.getRowValue(t.validated_content, n.cols[e], n).long, i = S(e, t.data_issues, r);
539
543
  if (i.length === 0) return /* @__PURE__ */ Q(Z, { children: r });
540
544
  let o = c.palette.info.main;
541
545
  p.includes(i[0].data_issue_type) ? o = c.palette.error.main : m.includes(i[0].data_issue_type) && (o = c.palette.warning.main);
542
546
  let s = i.find((e) => e.original_value)?.original_value || "", l = /* @__PURE__ */ $(Z, { children: [s && r && s !== r && /* @__PURE__ */ $(Z, { children: [/* @__PURE__ */ Q("s", { children: s }), "\xA0"] }), r && /* @__PURE__ */ Q(Z, { children: r })] });
543
- return /* @__PURE__ */ $(L, {
547
+ return /* @__PURE__ */ $(I, {
544
548
  sx: {
545
549
  alignItems: "center",
546
550
  display: "flex"
547
551
  },
548
- children: [/* @__PURE__ */ Q(L, {
552
+ children: [/* @__PURE__ */ Q(I, {
549
553
  sx: {
550
554
  height: c.spacing(2),
551
555
  marginRight: c.spacing(1),
@@ -554,10 +558,10 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
554
558
  position: "relative",
555
559
  width: c.spacing(2)
556
560
  },
557
- children: /* @__PURE__ */ Q(ce, {
561
+ children: /* @__PURE__ */ Q(ae, {
558
562
  arrow: !0,
559
563
  title: y(i),
560
- children: /* @__PURE__ */ Q(De, {
564
+ children: /* @__PURE__ */ Q(Ee, {
561
565
  fontSize: "small",
562
566
  sx: {
563
567
  color: o,
@@ -566,7 +570,7 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
566
570
  }
567
571
  })
568
572
  })
569
- }), /* @__PURE__ */ Q(L, {
573
+ }), /* @__PURE__ */ Q(I, {
570
574
  sx: {
571
575
  overflow: "hidden",
572
576
  textOverflow: "ellipsis",
@@ -578,16 +582,16 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
578
582
  }, [
579
583
  n,
580
584
  p,
581
- x,
585
+ S,
582
586
  y,
583
587
  c,
584
588
  m
585
- ]), O = q(() => {
589
+ ]), k = q(() => {
586
590
  let i = [];
587
591
  if (!t?.length) return i;
588
- i.push(Me.createReadableIndexColumn()), i.push(Me.createSelectableColumn()), i.push({
592
+ i.push(je.createReadableIndexColumn()), i.push(je.createSelectableColumn()), i.push({
589
593
  disableEllipsis: !0,
590
- frozen: je.LEFT,
594
+ frozen: Ae.LEFT,
591
595
  headerName: "",
592
596
  hideInFilter: !0,
593
597
  id: "gen-epix-ui-issue",
@@ -600,7 +604,7 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
600
604
  widthPx: 38
601
605
  }), i.push({
602
606
  disableEllipsis: !0,
603
- frozen: je.LEFT,
607
+ frozen: Ae.LEFT,
604
608
  headerName: "",
605
609
  hideInFilter: !0,
606
610
  id: "gen-epix-ui-id",
@@ -617,7 +621,7 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
617
621
  Object.keys(e.validated_content || {}).forEach((e) => o.add(e)), e.data_issues.forEach((e) => o.add(e.col_id));
618
622
  }), n.ordered_col_ids.forEach((s) => {
619
623
  if (!o.has(s)) return;
620
- let c = n.cols[s], u = t.flatMap((e) => e.data_issues.filter((e) => e.col_id === c.id)), d = u.length === 0 || u.some((e) => e.data_issue_type !== A.DERIVED), f = e[c.id]?.length;
624
+ let c = n.cols[s], u = t.flatMap((e) => e.data_issues.filter((e) => e.col_id === c.id)), d = u.length === 0 || u.some((e) => e.data_issue_type !== D.DERIVED), f = e[c.id]?.length;
621
625
  c && i.push({
622
626
  cellTitleGetter: (e) => {
623
627
  let t = e.row.data_issues.find((e) => e.col_id === c.id);
@@ -631,7 +635,7 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
631
635
  return "";
632
636
  },
633
637
  customHeaderIcon: f ? {
634
- iconElement: /* @__PURE__ */ Q(Ee, { fontSize: "inherit" }),
638
+ iconElement: /* @__PURE__ */ Q(Te, { fontSize: "inherit" }),
635
639
  label: l("Edit values for {{colLabel}} (for selected rows)", { colLabel: c.label }),
636
640
  onClick: h
637
641
  } : void 0,
@@ -639,7 +643,7 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
639
643
  hideInFilter: !0,
640
644
  id: c.id,
641
645
  isInitiallyVisible: d,
642
- renderCell: D,
646
+ renderCell: O,
643
647
  type: "text",
644
648
  valueGetter: (e) => a.getRowValue(e.row.validated_content, c, n).short,
645
649
  widthPx: 250
@@ -652,10 +656,10 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
652
656
  type: "text",
653
657
  valueGetter: (e) => e.row.id || "",
654
658
  widthPx: 250
655
- }), i.push(Me.createActionsColumn({
659
+ }), i.push(je.createActionsColumn({
656
660
  getActions: (e) => {
657
661
  let t = [];
658
- return t.push(/* @__PURE__ */ $(ie, {
662
+ return t.push(/* @__PURE__ */ $(z, {
659
663
  onClick: () => {
660
664
  u.current?.open({
661
665
  caseContent: e.row.validated_content,
@@ -665,7 +669,7 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
665
669
  formId: "edit-case-form"
666
670
  });
667
671
  },
668
- children: [/* @__PURE__ */ Q(z, { children: /* @__PURE__ */ Q(Ee, {}) }), /* @__PURE__ */ Q(B, { children: l`Edit` })]
672
+ children: [/* @__PURE__ */ Q(ne, { children: /* @__PURE__ */ Q(Te, {}) }), /* @__PURE__ */ Q(R, { children: l`Edit` })]
669
673
  }, "editCase")), t;
670
674
  },
671
675
  t: l
@@ -680,21 +684,21 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
680
684
  l,
681
685
  e,
682
686
  h,
683
- D,
687
+ O,
684
688
  r
685
689
  ]);
686
- return Ne({
687
- columns: O,
690
+ return Me({
691
+ columns: k,
688
692
  createFiltersFromColumns: !0,
689
693
  rows: t,
690
694
  store: s
691
695
  }), /* @__PURE__ */ $(Z, { children: [
692
- /* @__PURE__ */ Q(L, { children: /* @__PURE__ */ Q(Ae, { ContainerProps: { sx: {
696
+ /* @__PURE__ */ Q(I, { children: /* @__PURE__ */ Q(ke, { ContainerProps: { sx: {
693
697
  display: "inline-block",
694
698
  float: "right"
695
699
  } } }) }),
696
- /* @__PURE__ */ Q(ke, { font: c["gen-epix-ui-client-casedb"].lineList.font }),
697
- /* @__PURE__ */ Q(S, {
700
+ /* @__PURE__ */ Q(Oe, { font: c["gen-epix-ui-client-casedb"].lineList.font }),
701
+ /* @__PURE__ */ Q(b, {
698
702
  onSubmit: g,
699
703
  ref: u
700
704
  }),
@@ -704,7 +708,7 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
704
708
  })
705
709
  ] });
706
710
  }, Ye = ({ onGoBackButtonClick: e, onProceedButtonClick: t }) => {
707
- let { t: n } = X(), r = me(), i = W(p), a = l(i, (e) => e.completeCaseType), o = l(r, (e) => e.selectedIds), s = !o.length || o.length > a.props.create_max_n_cases;
711
+ let { t: n } = X(), r = de(), i = W(p), a = l(i, (e) => e.completeCaseType), o = l(r, (e) => e.selectedIds), s = !o.length || o.length > a.props.create_max_n_cases;
708
712
  return /* @__PURE__ */ Q(Ve, {
709
713
  onGoBackButtonClick: e,
710
714
  onProceedButtonClick: t,
@@ -712,14 +716,14 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
712
716
  proceedLabel: o.length ? n("Proceed with {{count}} selected cases", { count: o.length }) : n("Proceed")
713
717
  });
714
718
  }, Xe = Ke(({ caseTypeId: e }) => {
715
- let { t } = X(), n = W(p), r = l(n, (e) => e.goToNextStep), i = l(n, (e) => e.goToPreviousStep), o = l(n, (e) => e.completeCaseType), s = l(n, (e) => e.casesForVerificationFromSourceData), c = l(n, (e) => e.createdInDataCollectionId), u = l(n, (e) => e.validateCasesQueryKey), f = l(n, (e) => e.caseRightsColMap), [m, h] = Y(!1), [g, _] = Y(!1), [v, y] = Y(null), b = J([]), x = J(null), S = J(null), C = G((e, t, n) => s[t.rowIndex]?.case?.content[e.id] ?? "", [s]), w = xe({
719
+ let { t } = X(), n = W(p), r = l(n, (e) => e.goToNextStep), i = l(n, (e) => e.goToPreviousStep), o = l(n, (e) => e.completeCaseType), s = l(n, (e) => e.casesForVerificationFromSourceData), c = l(n, (e) => e.createdInDataCollectionId), u = l(n, (e) => e.validateCasesQueryKey), f = l(n, (e) => e.caseRightsColMap), [m, h] = Y(!1), [g, _] = Y(!1), [v, y] = Y(null), b = J([]), x = J(null), S = J(null), C = G((e, t, n) => s[t.rowIndex]?.case?.content[e.id] ?? "", [s]), w = be({
716
720
  enabled: s.length > 0,
717
721
  gcTime: Infinity,
718
- queryFn: async ({ signal: t }) => (await k.getInstance().uploadCases(N.deepNullifyEmptyStrings({
722
+ queryFn: async ({ signal: t }) => (await E.getInstance().uploadCases(A.deepNullifyEmptyStrings({
719
723
  case_batch: { cases: s },
720
724
  case_type_id: e,
721
725
  default_created_in_data_collection_id: c ?? void 0,
722
- on_exists: M.UPDATE,
726
+ on_exists: k.UPDATE,
723
727
  verify_only: !0
724
728
  }), { signal: t })).data,
725
729
  queryKey: u,
@@ -728,10 +732,10 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
728
732
  id: s[t].id
729
733
  })),
730
734
  staleTime: Infinity
731
- }), T = _e([w]), E = q(() => pe({ idSelectorCallback: (e) => e.id }), []), D = l(E, d((e) => e.setSelectedIds)), O = G(async (t) => {
735
+ }), T = me([w]), j = q(() => ue({ idSelectorCallback: (e) => e.id }), []), M = l(j, d((e) => e.setSelectedIds)), F = G(async (t) => {
732
736
  _(!0);
733
737
  try {
734
- let n = (await k.getInstance().uploadCases(N.deepNullifyEmptyStrings({
738
+ let n = (await E.getInstance().uploadCases(A.deepNullifyEmptyStrings({
735
739
  case_batch: { cases: t.map(({ content: e, row: t }, n) => {
736
740
  let r = s.find((e) => e.id === t.id);
737
741
  return { case: {
@@ -748,7 +752,7 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
748
752
  }) },
749
753
  case_type_id: e,
750
754
  default_created_in_data_collection_id: c ?? void 0,
751
- on_exists: M.UPDATE,
755
+ on_exists: k.UPDATE,
752
756
  verify_only: !0
753
757
  }))).data, r = new Map(t.map(({ row: e }, t) => [e.id, n.cases[t]]));
754
758
  ee.getInstance().queryClient.setQueryData(u, { cases: w.data.map((e) => {
@@ -761,10 +765,10 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
761
765
  let i = [];
762
766
  if (t.forEach(({ row: e }, t) => {
763
767
  let r = n.cases[t];
764
- r.status !== j.SKIPPED && r.status !== j.SUCCESS && r.status !== j.UPDATED && (b.current.includes(e.id) || (b.current.push(e.id), i.push(e.id)));
768
+ r.status !== O.SKIPPED && r.status !== O.SUCCESS && r.status !== O.UPDATED && (b.current.includes(e.id) || (b.current.push(e.id), i.push(e.id)));
765
769
  }), i.length > 0) {
766
- let e = E.getState().selectedIds, t = i.filter((t) => !e.includes(t));
767
- t.length > 0 && D([...e, ...t]);
770
+ let e = j.getState().selectedIds, t = i.filter((t) => !e.includes(t));
771
+ t.length > 0 && M([...e, ...t]);
768
772
  }
769
773
  } catch (e) {
770
774
  y(e);
@@ -777,12 +781,12 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
777
781
  s,
778
782
  o,
779
783
  c,
780
- D,
781
- E,
784
+ M,
785
+ j,
782
786
  u
783
- ]), P = G(async (e) => {
784
- let t = E.getState().selectedIds;
785
- await O(w.data.filter((e) => t.includes(e.id)).map((t) => ({
787
+ ]), L = G(async (e) => {
788
+ let t = j.getState().selectedIds;
789
+ await F(w.data.filter((e) => t.includes(e.id)).map((t) => ({
786
790
  content: {
787
791
  ...t.validated_content,
788
792
  ...e[t.id]
@@ -791,17 +795,17 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
791
795
  })));
792
796
  }, [
793
797
  w.data,
794
- O,
795
- E
798
+ F,
799
+ j
796
800
  ]), te = G(async (e, t) => {
797
801
  let n = w.data.find((t) => t.id === e);
798
- await O([{
802
+ await F([{
799
803
  content: t,
800
804
  row: n
801
805
  }]);
802
- }, [w.data, O]);
806
+ }, [w.data, F]);
803
807
  K(() => {
804
- let e = E.subscribe((e, t) => {
808
+ let e = j.subscribe((e, t) => {
805
809
  if (e.selectedIds === t.selectedIds) return;
806
810
  b.current = e.selectedIds;
807
811
  let n = e.selectedIds.length > o.props.create_max_n_cases;
@@ -810,12 +814,12 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
810
814
  return () => {
811
815
  e();
812
816
  };
813
- }, [o.props.create_max_n_cases, E]), K(() => {
814
- let e = (w.data ?? []).filter((e) => !e.data_issues.some((e) => e.data_issue_type === A.INVALID || e.data_issue_type === A.UNAUTHORIZED)).map((e) => e.id);
815
- D(e);
816
- }, [w.data, D]);
817
+ }, [o.props.create_max_n_cases, j]), K(() => {
818
+ let e = (w.data ?? []).filter((e) => !e.data_issues.some((e) => e.data_issue_type === D.INVALID || e.data_issue_type === D.UNAUTHORIZED)).map((e) => e.id);
819
+ M(e);
820
+ }, [w.data, M]);
817
821
  let ne = G(async () => {
818
- let e = E.getState().selectedIds, t = w.data.filter((t) => e.includes(t.id) && !t.data_issues.some((e) => e.data_issue_type === A.INVALID));
822
+ let e = j.getState().selectedIds, t = w.data.filter((t) => e.includes(t.id) && !t.data_issues.some((e) => e.data_issue_type === D.INVALID));
819
823
  n.setState((e) => ({
820
824
  ...e,
821
825
  selectedIdsForUpload: t.map((e) => e.id),
@@ -825,7 +829,7 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
825
829
  w.data,
826
830
  r,
827
831
  n,
828
- E
832
+ j
829
833
  ]), R = G(async () => {
830
834
  n.setState((e) => ({
831
835
  ...e,
@@ -836,12 +840,12 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
836
840
  r,
837
841
  w.data,
838
842
  n
839
- ]), re = G(async () => {
840
- if (w.data.some((e) => E.getState().selectedIds.includes(e.id) && (e.data_issues.some((e) => e.data_issue_type === A.INVALID) || e.status === j.FAILED))) {
843
+ ]), z = G(async () => {
844
+ if (w.data.some((e) => j.getState().selectedIds.includes(e.id) && (e.data_issues.some((e) => e.data_issue_type === D.INVALID) || e.status === O.FAILED))) {
841
845
  x.current?.open();
842
846
  return;
843
847
  }
844
- if (w.data.some((e) => !E.getState().selectedIds.includes(e.id) && !e.data_issues.some((e) => e.data_issue_type === A.INVALID))) {
848
+ if (w.data.some((e) => !j.getState().selectedIds.includes(e.id) && !e.data_issues.some((e) => e.data_issue_type === D.INVALID))) {
845
849
  S.current?.open();
846
850
  return;
847
851
  }
@@ -849,11 +853,11 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
849
853
  }, [
850
854
  w.data,
851
855
  R,
852
- E
853
- ]), z = G(() => {
856
+ j
857
+ ]), B = G(() => {
854
858
  i();
855
859
  }, [i]);
856
- return /* @__PURE__ */ $(L, {
860
+ return /* @__PURE__ */ $(I, {
857
861
  sx: {
858
862
  display: "grid",
859
863
  gridTemplateRows: `${m ? "max-content" : ""} max-content auto max-content`,
@@ -862,20 +866,20 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
862
866
  width: "100%"
863
867
  },
864
868
  children: [
865
- /* @__PURE__ */ Q(fe, {
866
- store: E,
867
- children: /* @__PURE__ */ $(he, {
869
+ /* @__PURE__ */ Q(le, {
870
+ store: j,
871
+ children: /* @__PURE__ */ $(fe, {
868
872
  error: v,
869
873
  inlineSpinner: !0,
870
874
  loadables: T,
871
875
  loadingMessage: t("Validating cases"),
872
876
  takingLongerTimeoutMs: 1e4,
873
877
  children: [
874
- m && /* @__PURE__ */ Q(L, {
878
+ m && /* @__PURE__ */ Q(I, {
875
879
  sx: { marginY: 2 },
876
- children: /* @__PURE__ */ Q(F, {
880
+ children: /* @__PURE__ */ Q(N, {
877
881
  severity: "error",
878
- children: /* @__PURE__ */ Q(I, { children: t("You have exceeded the maximum number of {{maxCases}} cases for this case type. Please reduce the number of selected cases before proceeding.", { maxCases: o.props.create_max_n_cases }) })
882
+ children: /* @__PURE__ */ Q(P, { children: t("You have exceeded the maximum number of {{maxCases}} cases for this case type. Please reduce the number of selected cases before proceeding.", { maxCases: o.props.create_max_n_cases }) })
879
883
  })
880
884
  }),
881
885
  /* @__PURE__ */ Q(Je, {
@@ -884,21 +888,21 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
884
888
  completeCaseType: o,
885
889
  getOriginalCellValue: C,
886
890
  onCaseContentEditSubmit: te,
887
- onColContentEditSubmit: P,
888
- tableStore: E
891
+ onColContentEditSubmit: L,
892
+ tableStore: j
889
893
  }),
890
894
  /* @__PURE__ */ Q(Ye, {
891
- onGoBackButtonClick: z,
892
- onProceedButtonClick: re
895
+ onGoBackButtonClick: B,
896
+ onProceedButtonClick: z
893
897
  })
894
898
  ]
895
899
  })
896
900
  }),
897
- /* @__PURE__ */ Q(we, {
901
+ /* @__PURE__ */ Q(Ce, {
898
902
  label: t("Revalidating cases"),
899
903
  open: g
900
904
  }),
901
- /* @__PURE__ */ Q(Te, {
905
+ /* @__PURE__ */ Q(we, {
902
906
  body: t`Some of the selected cases contain issues. If you proceed, these cases will be excluded. Are you sure you want to proceed without them?`,
903
907
  cancelLabel: t`Cancel`,
904
908
  confirmLabel: t`Proceed`,
@@ -906,7 +910,7 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
906
910
  ref: x,
907
911
  title: t`Issues found with selected cases`
908
912
  }),
909
- /* @__PURE__ */ Q(Te, {
913
+ /* @__PURE__ */ Q(we, {
910
914
  body: t`Not all cases are selected. Do you want to proceed without them?`,
911
915
  cancelLabel: t`Cancel`,
912
916
  confirmLabel: t`Proceed`,
@@ -920,9 +924,9 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
920
924
  let { t: e } = X(), r = W(p), i = l(r, (e) => e.reset), a = l(r, (e) => e.goToPreviousStep), o = l(r, (e) => e.sequenceMapping), c = l(r, (e) => e.sequenceFilesDataTransfer), u = l(r, (e) => e.validatedCases), d = l(r, (e) => e.selectedIdsForUpload), f = l(r, (e) => e.casesForVerificationFromSourceData), m = l(r, (e) => e.uploadCompleteButtonCallback), h = l(r, (e) => e.uploadCompleteButtonLabel), g = l(r, (e) => e.onUploadComplete), _ = l(r, (e) => e.completeCaseType), [v, y] = Y(0), [b, x] = Y(""), [S, C] = Y(!1), [w, T] = Y(!1), [E, D] = Y(void 0), O = q(() => t.getSequenceMappingStats(o, c), [c, o]), k = q(() => u.filter((e) => d.includes(e.id)), [u, d]);
921
925
  K(() => {
922
926
  let e = new AbortController(), { signal: n } = e, i = () => {
923
- e.abort(), Re.getInstance().resume();
927
+ e.abort(), Le.getInstance().resume();
924
928
  };
925
- return S ? (Re.getInstance().pause(), (async () => {
929
+ return S ? (Le.getInstance().pause(), (async () => {
926
930
  let e = await t.createCasesAndUploadFiles({
927
931
  assemblyProtocolId: r.getState().assemblyProtocolId,
928
932
  casesForVerificationFromSourceData: f,
@@ -959,23 +963,23 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
959
963
  f,
960
964
  g
961
965
  ]);
962
- let A = G(async () => {
966
+ let ee = G(async () => {
963
967
  await i();
964
- }, [i]), j = G(() => {
968
+ }, [i]), A = G(() => {
965
969
  C(!0);
966
- }, []), M = G(() => {
970
+ }, []), j = G(() => {
967
971
  a();
968
- }, [a]), ee = G(async () => {
972
+ }, [a]), M = G(async () => {
969
973
  let e = n.createCaseTypeLink(_);
970
- await Be.getInstance().router.navigate(e);
971
- }, [_]), N;
972
- return N = E ? /* @__PURE__ */ $(L, { children: [E instanceof s && /* @__PURE__ */ $(F, {
974
+ await ze.getInstance().router.navigate(e);
975
+ }, [_]), F;
976
+ return F = E ? /* @__PURE__ */ $(I, { children: [E instanceof s && /* @__PURE__ */ $(N, {
973
977
  severity: "error",
974
- children: [/* @__PURE__ */ Q(I, { children: e("Failed to create cases during upload.") }), e("An error occurred while creating cases. Please try again or contact support if the issue persists. Cases may have been partially created. No files were uploaded.")]
975
- }), /* @__PURE__ */ Q(Le, { error: E })] }) : w ? /* @__PURE__ */ $(L, { children: [/* @__PURE__ */ Q(L, { children: /* @__PURE__ */ Q(F, {
978
+ children: [/* @__PURE__ */ Q(P, { children: e("Failed to create cases during upload.") }), e("An error occurred while creating cases. Please try again or contact support if the issue persists. Cases may have been partially created. No files were uploaded.")]
979
+ }), /* @__PURE__ */ Q(Ie, { error: E })] }) : w ? /* @__PURE__ */ $(I, { children: [/* @__PURE__ */ Q(I, { children: /* @__PURE__ */ Q(N, {
976
980
  severity: "success",
977
- children: /* @__PURE__ */ Q(I, { children: e("Upload completed.") })
978
- }) }), /* @__PURE__ */ Q(L, {
981
+ children: /* @__PURE__ */ Q(P, { children: e("Upload completed.") })
982
+ }) }), /* @__PURE__ */ Q(I, {
979
983
  sx: {
980
984
  display: "flex",
981
985
  gap: 2,
@@ -983,196 +987,196 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
983
987
  marginBottom: 1,
984
988
  marginTop: 2
985
989
  },
986
- children: m && h ? /* @__PURE__ */ Q(R, {
990
+ children: m && h ? /* @__PURE__ */ Q(L, {
987
991
  onClick: m,
988
992
  variant: "contained",
989
993
  children: h
990
- }) : /* @__PURE__ */ $(Z, { children: [/* @__PURE__ */ Q(R, {
991
- onClick: A,
994
+ }) : /* @__PURE__ */ $(Z, { children: [/* @__PURE__ */ Q(L, {
995
+ onClick: ee,
992
996
  variant: "outlined",
993
997
  children: e("Upload more cases")
994
- }), /* @__PURE__ */ Q(R, {
995
- onClick: ee,
998
+ }), /* @__PURE__ */ Q(L, {
999
+ onClick: M,
996
1000
  variant: "contained",
997
1001
  children: e("View uploaded cases")
998
1002
  })] })
999
- })] }) : S ? /* @__PURE__ */ $(L, { children: [
1000
- /* @__PURE__ */ Q(L, {
1003
+ })] }) : S ? /* @__PURE__ */ $(I, { children: [
1004
+ /* @__PURE__ */ Q(I, {
1001
1005
  sx: { marginBottom: 4 },
1002
- children: /* @__PURE__ */ $(F, {
1006
+ children: /* @__PURE__ */ $(N, {
1003
1007
  severity: "info",
1004
- children: [/* @__PURE__ */ Q(I, { children: e("Uploading cases and files.") }), e("Please wait while the cases and associated files are being uploaded. This may take a while depending on the number and size of the files being uploaded.")]
1008
+ children: [/* @__PURE__ */ Q(P, { children: e("Uploading cases and files.") }), e("Please wait while the cases and associated files are being uploaded. This may take a while depending on the number and size of the files being uploaded.")]
1005
1009
  })
1006
1010
  }),
1007
- /* @__PURE__ */ Q(L, {
1011
+ /* @__PURE__ */ Q(I, {
1008
1012
  sx: {
1009
1013
  marginBottom: 2,
1010
1014
  marginTop: 4
1011
1015
  },
1012
- children: /* @__PURE__ */ Q(ze, { value: v })
1016
+ children: /* @__PURE__ */ Q(Re, { value: v })
1013
1017
  }),
1014
- /* @__PURE__ */ Q(L, {
1018
+ /* @__PURE__ */ Q(I, {
1015
1019
  sx: { fontWeight: 700 },
1016
1020
  children: b
1017
1021
  })
1018
- ] }) : /* @__PURE__ */ $(L, { children: [/* @__PURE__ */ $(L, { children: [
1019
- /* @__PURE__ */ Q(L, {
1022
+ ] }) : /* @__PURE__ */ $(I, { children: [/* @__PURE__ */ $(I, { children: [
1023
+ /* @__PURE__ */ Q(I, {
1020
1024
  sx: { marginY: 2 },
1021
- children: /* @__PURE__ */ Q(F, {
1025
+ children: /* @__PURE__ */ Q(N, {
1022
1026
  severity: "info",
1023
- children: /* @__PURE__ */ Q(I, { children: e("{{numCases}} cases are ready to be uploaded.", { numCases: k.length }) })
1027
+ children: /* @__PURE__ */ Q(P, { children: e("{{numCases}} cases are ready to be uploaded.", { numCases: k.length }) })
1024
1028
  })
1025
1029
  }),
1026
- O.mappedSequenceFiles.length > 0 && /* @__PURE__ */ Q(L, {
1030
+ O.mappedSequenceFiles.length > 0 && /* @__PURE__ */ Q(I, {
1027
1031
  sx: { marginY: 2 },
1028
- children: /* @__PURE__ */ Q(F, {
1032
+ children: /* @__PURE__ */ Q(N, {
1029
1033
  severity: "info",
1030
- children: /* @__PURE__ */ Q(I, { children: e("{{numSequenceFiles}} genome files are ready to be uploaded.", { numSequenceFiles: O.mappedSequenceFiles.length }) })
1034
+ children: /* @__PURE__ */ Q(P, { children: e("{{numSequenceFiles}} genome files are ready to be uploaded.", { numSequenceFiles: O.mappedSequenceFiles.length }) })
1031
1035
  })
1032
1036
  }),
1033
- O.mappedReadsFiles.length > 0 && /* @__PURE__ */ Q(L, {
1037
+ O.mappedReadsFiles.length > 0 && /* @__PURE__ */ Q(I, {
1034
1038
  sx: { marginY: 2 },
1035
- children: /* @__PURE__ */ Q(F, {
1039
+ children: /* @__PURE__ */ Q(N, {
1036
1040
  severity: "info",
1037
- children: /* @__PURE__ */ Q(I, { children: e("{{numReadsFiles}} reads files are ready to be uploaded.", { numReadsFiles: O.mappedReadsFiles.length }) })
1041
+ children: /* @__PURE__ */ Q(P, { children: e("{{numReadsFiles}} reads files are ready to be uploaded.", { numReadsFiles: O.mappedReadsFiles.length }) })
1038
1042
  })
1039
1043
  }),
1040
- u.length - k.length > 0 && /* @__PURE__ */ Q(L, {
1044
+ u.length - k.length > 0 && /* @__PURE__ */ Q(I, {
1041
1045
  sx: { marginY: 2 },
1042
- children: /* @__PURE__ */ Q(F, {
1046
+ children: /* @__PURE__ */ Q(N, {
1043
1047
  severity: "warning",
1044
- children: /* @__PURE__ */ Q(I, { children: e("{{numCases}} cases were not selected and will not be uploaded.", { numCases: u.length - k.length }) })
1048
+ children: /* @__PURE__ */ Q(P, { children: e("{{numCases}} cases were not selected and will not be uploaded.", { numCases: u.length - k.length }) })
1045
1049
  })
1046
1050
  }),
1047
- O.unmappedSequenceFiles.length > 0 && /* @__PURE__ */ Q(L, {
1051
+ O.unmappedSequenceFiles.length > 0 && /* @__PURE__ */ Q(I, {
1048
1052
  sx: { marginY: 2 },
1049
- children: /* @__PURE__ */ Q(F, {
1053
+ children: /* @__PURE__ */ Q(N, {
1050
1054
  severity: "warning",
1051
- children: /* @__PURE__ */ Q(I, { children: e("{{unmappedSequenceFiles}} unmapped genome files will not be uploaded.", { unmappedSequenceFiles: O.unmappedSequenceFiles.length }) })
1055
+ children: /* @__PURE__ */ Q(P, { children: e("{{unmappedSequenceFiles}} unmapped genome files will not be uploaded.", { unmappedSequenceFiles: O.unmappedSequenceFiles.length }) })
1052
1056
  })
1053
1057
  }),
1054
- O.unmappedReadsFiles.length > 0 && /* @__PURE__ */ Q(L, {
1058
+ O.unmappedReadsFiles.length > 0 && /* @__PURE__ */ Q(I, {
1055
1059
  sx: { marginY: 2 },
1056
- children: /* @__PURE__ */ Q(F, {
1060
+ children: /* @__PURE__ */ Q(N, {
1057
1061
  severity: "warning",
1058
- children: /* @__PURE__ */ Q(I, { children: e("{{unmappedReadsFiles}} unmapped reads files will not be uploaded.", { unmappedReadsFiles: O.unmappedReadsFiles.length }) })
1062
+ children: /* @__PURE__ */ Q(P, { children: e("{{unmappedReadsFiles}} unmapped reads files will not be uploaded.", { unmappedReadsFiles: O.unmappedReadsFiles.length }) })
1059
1063
  })
1060
1064
  })
1061
1065
  ] }), /* @__PURE__ */ Q(Ve, {
1062
- onGoBackButtonClick: M,
1063
- onProceedButtonClick: j,
1066
+ onGoBackButtonClick: j,
1067
+ onProceedButtonClick: A,
1064
1068
  proceedLabel: "Start upload"
1065
- })] }), /* @__PURE__ */ Q(re, {
1069
+ })] }), /* @__PURE__ */ Q(te, {
1066
1070
  maxWidth: "xl",
1067
1071
  sx: { height: "100%" },
1068
- children: N
1072
+ children: F
1069
1073
  });
1070
- }, Qe = (e) => Array.from(e?.files ?? []), $e = ({ hasGenomeFiles: e, hasReadsFiles: t, hasSelectedFiles: n }) => D().shape({
1071
- assemblyProtocolId: e ? O().uuid4().required() : O().nullable().notRequired(),
1072
- sampleIdColId: n ? O().uuid4().required() : O().nullable().notRequired(),
1073
- sequencingProtocolId: t ? O().uuid4().required() : O().nullable().notRequired()
1074
+ }, Qe = (e) => Array.from(e?.files ?? []), $e = ({ hasGenomeFiles: e, hasReadsFiles: t, hasSelectedFiles: n }) => w().shape({
1075
+ assemblyProtocolId: e ? T().uuid4().required() : T().nullable().notRequired(),
1076
+ sampleIdColId: n ? T().uuid4().required() : T().nullable().notRequired(),
1077
+ sequencingProtocolId: t ? T().uuid4().required() : T().nullable().notRequired()
1074
1078
  }), et = () => {
1075
- let { t: e } = X(), n = ue(), r = W(p), i = l(r, (e) => e.completeCaseType), a = l(r, (e) => e.mappedColumns), o = l(r, (e) => e.validatedCases), s = l(r, (e) => e.goToNextStep), c = l(r, (e) => e.goToPreviousStep), u = l(r, (e) => e.setSequenceFilesDataTransfer), d = l(r, (e) => e.sampleIdColId), f = l(r, (e) => e.sequenceFilesDataTransfer), [m, _] = Y(f), v = de(), y = w(), b = T(), x = _e([y, b]), S = q(() => a.filter((e) => e.isSampleIdColumn).map((e) => ({
1079
+ let { t: e } = X(), n = se(), r = W(p), i = l(r, (e) => e.completeCaseType), a = l(r, (e) => e.mappedColumns), o = l(r, (e) => e.validatedCases), s = l(r, (e) => e.goToNextStep), c = l(r, (e) => e.goToPreviousStep), u = l(r, (e) => e.setSequenceFilesDataTransfer), d = l(r, (e) => e.sampleIdColId), f = l(r, (e) => e.sequenceFilesDataTransfer), [h, g] = Y(f), _ = ce(), v = x(), y = S(), b = me([v, y]), C = q(() => a.filter((e) => e.isSampleIdColumn).map((e) => ({
1076
1080
  label: e.col.label,
1077
1081
  value: e.col.id
1078
- })), [a]), E = q(() => Qe(m), [m]), D = E.length > 0, O = q(() => E.some((e) => t.isGenomeFile(e.name)), [E]), k = q(() => E.some((e) => t.isReadsFile(e.name)), [E]), A = q(() => $e({
1079
- hasGenomeFiles: O,
1080
- hasReadsFiles: k,
1081
- hasSelectedFiles: D
1082
+ })), [a]), w = q(() => Qe(h), [h]), T = w.length > 0, E = q(() => w.some((e) => t.isGenomeFile(e.name)), [w]), D = q(() => w.some((e) => t.isReadsFile(e.name)), [w]), O = q(() => $e({
1083
+ hasGenomeFiles: E,
1084
+ hasReadsFiles: D,
1085
+ hasSelectedFiles: T
1082
1086
  }), [
1083
- O,
1084
- k,
1085
- D
1086
- ]), j = q(() => ({
1087
+ E,
1088
+ D,
1089
+ T
1090
+ ]), k = q(() => ({
1087
1091
  assemblyProtocolId: r.getState().assemblyProtocolId ?? null,
1088
1092
  sampleIdColId: r.getState().sampleIdColId ?? null,
1089
1093
  sequencingProtocolId: r.getState().sequencingProtocolId ?? null
1090
- }), [r]), M = h({
1091
- defaultValues: j,
1092
- resolver: g(A),
1093
- values: j
1094
- }), { handleSubmit: ee, setValue: N } = M;
1094
+ }), [r]), ee = _e({
1095
+ defaultValues: k,
1096
+ resolver: m(O),
1097
+ values: k
1098
+ }), { handleSubmit: A, setValue: M } = ee;
1095
1099
  K(() => {
1096
- y.isLoading || b.isLoading || (r.getState().sequencingProtocolId || (N("sequencingProtocolId", y.options[0]?.value || null), r.setState({ sequencingProtocolId: y.options[0]?.value || null })), r.getState().assemblyProtocolId || (N("assemblyProtocolId", b.options[0]?.value || null), r.setState({ assemblyProtocolId: b.options[0]?.value || null })), r.getState().sampleIdColId || (N("sampleIdColId", S[0]?.value || null), r.setState({ sampleIdColId: S[0]?.value || null })));
1100
+ v.isLoading || y.isLoading || (r.getState().sequencingProtocolId || (M("sequencingProtocolId", v.options[0]?.value || null), r.setState({ sequencingProtocolId: v.options[0]?.value || null })), r.getState().assemblyProtocolId || (M("assemblyProtocolId", y.options[0]?.value || null), r.setState({ assemblyProtocolId: y.options[0]?.value || null })), r.getState().sampleIdColId || (M("sampleIdColId", C[0]?.value || null), r.setState({ sampleIdColId: C[0]?.value || null })));
1097
1101
  }, [
1098
- b.isLoading,
1099
- b.options,
1100
1102
  y.isLoading,
1101
1103
  y.options,
1102
- N,
1104
+ v.isLoading,
1105
+ v.options,
1106
+ M,
1103
1107
  r,
1104
- S
1108
+ C
1105
1109
  ]);
1106
- let te = G((e) => {
1110
+ let F = G((e) => {
1107
1111
  r.setState({ sequencingProtocolId: e });
1108
- }, [r]), ne = G((e) => {
1112
+ }, [r]), L = G((e) => {
1109
1113
  r.setState({ assemblyProtocolId: e });
1110
- }, [r]), R = G((e) => {
1114
+ }, [r]), te = G((e) => {
1111
1115
  r.setState({ sampleIdColId: e });
1112
- }, [r]), re = q(() => [
1116
+ }, [r]), ne = q(() => [
1113
1117
  {
1114
- definition: P.SELECT,
1118
+ definition: j.SELECT,
1115
1119
  label: e`Genome files: assembly protocol`,
1116
- loading: b.isLoading,
1120
+ loading: y.isLoading,
1117
1121
  name: "assemblyProtocolId",
1118
- onChange: ne,
1119
- options: b.options
1122
+ onChange: L,
1123
+ options: y.options
1120
1124
  },
1121
1125
  {
1122
- definition: P.SELECT,
1126
+ definition: j.SELECT,
1123
1127
  label: e`Reads files: sequencing protocol`,
1124
- loading: y.isLoading,
1128
+ loading: v.isLoading,
1125
1129
  name: "sequencingProtocolId",
1126
- onChange: te,
1127
- options: y.options
1130
+ onChange: F,
1131
+ options: v.options
1128
1132
  },
1129
1133
  {
1130
- definition: P.SELECT,
1134
+ definition: j.SELECT,
1131
1135
  label: e`Sample ID column`,
1132
1136
  name: "sampleIdColId",
1133
- onChange: R,
1134
- options: S
1137
+ onChange: te,
1138
+ options: C
1135
1139
  }
1136
1140
  ], [
1137
- b.isLoading,
1138
- b.options,
1139
- ne,
1140
- R,
1141
- te,
1142
- S,
1143
1141
  y.isLoading,
1144
1142
  y.options,
1143
+ L,
1144
+ te,
1145
+ F,
1146
+ C,
1147
+ v.isLoading,
1148
+ v.options,
1145
1149
  e
1146
- ]), z = q(() => a.some((e) => e.isSampleIdColumn && e.sampleIdentifierIssuerId), [a]), B = q(() => d ? o.some((e) => e.validated_content[d]?.trim().length > 0) : !1, [d, o]), ie = q(() => t.getCompleteCaseTypeColStats(i), [i]), V = q(() => ie.sequenceColumns.length > 0, [ie]), H = q(() => ie.readsColumns.length > 0, [ie]), U = q(() => z && B && (V || H), [
1150
+ ]), R = q(() => a.some((e) => e.isSampleIdColumn && e.sampleIdentifierIssuerId), [a]), z = q(() => d ? o.some((e) => e.validated_content[d]?.trim().length > 0) : !1, [d, o]), B = q(() => t.getCompleteCaseTypeColStats(i), [i]), V = q(() => B.sequenceColumns.length > 0, [B]), H = q(() => B.readsColumns.length > 0, [B]), U = q(() => R && z && (V || H), [
1151
+ R,
1147
1152
  z,
1148
- B,
1149
1153
  V,
1150
1154
  H
1151
- ]), ae = q(() => {
1155
+ ]), re = q(() => {
1152
1156
  let e = "";
1153
1157
  return V && (e += ".fa,.fasta,.fa.gz,.fasta.gz,"), H && (e += ".fq,.fastq,.fq.gz,.fastq.gz,"), e;
1154
- }, [H, V]), oe = G(async () => {
1155
- u(U ? m : new DataTransfer()), await ee(async () => {
1158
+ }, [H, V]), ie = G(async () => {
1159
+ u(U ? h : new DataTransfer()), await A(async () => {
1156
1160
  await s();
1157
1161
  })();
1158
1162
  }, [
1159
1163
  U,
1160
- m,
1164
+ h,
1161
1165
  s,
1162
- ee,
1166
+ A,
1163
1167
  u
1164
- ]), se = G(() => {
1168
+ ]), ae = G(() => {
1165
1169
  c();
1166
- }, [c]), ce = G((e) => {
1167
- _(e), u(e);
1168
- }, [u]), le = G((e) => /* @__PURE__ */ Q(L, {
1170
+ }, [c]), oe = G((e) => {
1171
+ g(e), u(e);
1172
+ }, [u]), J = G((e) => /* @__PURE__ */ Q(I, {
1169
1173
  sx: {
1170
1174
  display: "grid",
1171
1175
  gap: n.spacing(1),
1172
1176
  gridTemplateColumns: "1fr 1fr 1fr"
1173
1177
  },
1174
1178
  children: e
1175
- }), [n]), J = q(() => z ? B ? H ? V ? null : {
1179
+ }), [n]), le = q(() => R ? z ? H ? V ? null : {
1176
1180
  message: e`The selected case type does not support uploading sequence files.`,
1177
1181
  title: e("Uploading of sequence files is disabled.")
1178
1182
  } : {
@@ -1187,13 +1191,13 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
1187
1191
  }, [
1188
1192
  H,
1189
1193
  V,
1190
- B,
1191
1194
  z,
1195
+ R,
1192
1196
  e
1193
- ]), fe = G(() => {}, []);
1194
- return /* @__PURE__ */ Q(he, {
1195
- loadables: x,
1196
- children: /* @__PURE__ */ $(L, {
1197
+ ]), ue = G(() => {}, []);
1198
+ return /* @__PURE__ */ Q(fe, {
1199
+ loadables: b,
1200
+ children: /* @__PURE__ */ $(I, {
1197
1201
  sx: {
1198
1202
  display: "grid",
1199
1203
  gridTemplateRows: `${U ? "" : "max-content "}max-content auto max-content`,
@@ -1201,46 +1205,46 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
1201
1205
  position: "relative"
1202
1206
  },
1203
1207
  children: [
1204
- !U && /* @__PURE__ */ Q(L, {
1208
+ !U && /* @__PURE__ */ Q(I, {
1205
1209
  sx: { marginBottom: 2 },
1206
- children: /* @__PURE__ */ $(F, {
1210
+ children: /* @__PURE__ */ $(N, {
1207
1211
  severity: "error",
1208
- children: [/* @__PURE__ */ Q(I, { children: J.title }), J.message]
1212
+ children: [/* @__PURE__ */ Q(P, { children: le.title }), le.message]
1209
1213
  })
1210
1214
  }),
1211
- /* @__PURE__ */ $(L, {
1215
+ /* @__PURE__ */ $(I, {
1212
1216
  sx: { borderBottom: `1px solid ${n.palette.divider}` },
1213
1217
  children: [
1214
- /* @__PURE__ */ Q(L, {
1218
+ /* @__PURE__ */ Q(I, {
1215
1219
  sx: { maxWidth: n.spacing(128) },
1216
- children: /* @__PURE__ */ Q(be, {
1217
- formFieldDefinitions: re,
1218
- formId: v,
1219
- formMethods: M,
1220
- onSubmit: fe,
1221
- schema: A,
1222
- wrapForm: le
1220
+ children: /* @__PURE__ */ Q(ye, {
1221
+ formFieldDefinitions: ne,
1222
+ formId: _,
1223
+ formMethods: ee,
1224
+ onSubmit: ue,
1225
+ schema: O,
1226
+ wrapForm: J
1223
1227
  })
1224
1228
  }),
1225
- !V && /* @__PURE__ */ Q(L, {
1229
+ !V && /* @__PURE__ */ Q(I, {
1226
1230
  sx: { marginY: 1 },
1227
- children: /* @__PURE__ */ $(F, {
1231
+ children: /* @__PURE__ */ $(N, {
1228
1232
  severity: "info",
1229
- children: [/* @__PURE__ */ Q(I, { children: e("Uploading of sequences has been disabled.") }), /* @__PURE__ */ Q(L, { children: e("Uploading of sequences is not supported for the selected case type.") })]
1233
+ children: [/* @__PURE__ */ Q(P, { children: e("Uploading of sequences has been disabled.") }), /* @__PURE__ */ Q(I, { children: e("Uploading of sequences is not supported for the selected case type.") })]
1230
1234
  })
1231
1235
  }),
1232
- !H && /* @__PURE__ */ Q(L, {
1236
+ !H && /* @__PURE__ */ Q(I, {
1233
1237
  sx: { marginY: 1 },
1234
- children: /* @__PURE__ */ $(F, {
1238
+ children: /* @__PURE__ */ $(N, {
1235
1239
  severity: "info",
1236
- children: [/* @__PURE__ */ Q(I, { children: e("Uploading of read files has been disabled.") }), /* @__PURE__ */ Q(L, { children: e("Uploading of read files is not supported for the selected case type.") })]
1240
+ children: [/* @__PURE__ */ Q(P, { children: e("Uploading of read files has been disabled.") }), /* @__PURE__ */ Q(I, { children: e("Uploading of read files is not supported for the selected case type.") })]
1237
1241
  })
1238
1242
  })
1239
1243
  ]
1240
1244
  }),
1241
- /* @__PURE__ */ Q(L, {
1245
+ /* @__PURE__ */ Q(I, {
1242
1246
  sx: { position: "relative" },
1243
- children: /* @__PURE__ */ Q(L, {
1247
+ children: /* @__PURE__ */ Q(I, {
1244
1248
  sx: {
1245
1249
  bottom: 0,
1246
1250
  height: "100%",
@@ -1249,27 +1253,27 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
1249
1253
  right: 0,
1250
1254
  top: 0
1251
1255
  },
1252
- children: U && /* @__PURE__ */ Q(C, {
1253
- accept: ae,
1256
+ children: U && /* @__PURE__ */ Q(Be, {
1257
+ accept: re,
1254
1258
  initialDataTransfer: f,
1255
1259
  numFilesAllowed: Infinity,
1256
- onDataTransferChange: ce
1260
+ onDataTransferChange: oe
1257
1261
  })
1258
1262
  })
1259
1263
  }),
1260
1264
  /* @__PURE__ */ Q(Ve, {
1261
- onGoBackButtonClick: se,
1262
- onProceedButtonClick: oe,
1265
+ onGoBackButtonClick: ae,
1266
+ onProceedButtonClick: ie,
1263
1267
  proceedLabel: U ? void 0 : e`Proceed`
1264
1268
  })
1265
1269
  ]
1266
1270
  })
1267
1271
  });
1268
1272
  }, tt = () => {
1269
- let { t: e } = X(), n = ue(), r = W(p), i = l(r, (e) => e.goToNextStep), o = l(r, (e) => e.goToPreviousStep), s = l(r, (e) => e.completeCaseType), c = l(r, (e) => e.sampleIdColId), u = l(r, (e) => e.sequenceFilesDataTransfer), f = l(r, d((e) => {
1273
+ let { t: e } = X(), n = se(), r = W(p), i = l(r, (e) => e.goToNextStep), o = l(r, (e) => e.goToPreviousStep), s = l(r, (e) => e.completeCaseType), c = l(r, (e) => e.sampleIdColId), u = l(r, (e) => e.sequenceFilesDataTransfer), f = l(r, d((e) => {
1270
1274
  let t = e.selectedIdsForUpload;
1271
1275
  return e.validatedCases.filter((e) => t.includes(e.id));
1272
- })), m = l(r, (e) => e.setSequenceMapping), h = q(() => t.getCompleteCaseTypeColStats(s), [s]), g = de(), _ = de(), v = J(r.getState().sequenceMapping), y = G(async () => {
1276
+ })), m = l(r, (e) => e.setSequenceMapping), h = q(() => t.getCompleteCaseTypeColStats(s), [s]), g = ce(), _ = ce(), v = J(r.getState().sequenceMapping), y = G(async () => {
1273
1277
  m(v.current), await i();
1274
1278
  }, [m, i]), b = G(() => {
1275
1279
  o();
@@ -1290,19 +1294,19 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
1290
1294
  K(() => {
1291
1295
  x();
1292
1296
  }, [x]);
1293
- let S = q(() => pe({ idSelectorCallback: (e) => e.id }), []), C = G((e, t) => e.some((e) => {
1297
+ let S = q(() => ue({ idSelectorCallback: (e) => e.id }), []), C = G((e, t) => e.some((e) => {
1294
1298
  let n = a.getRowValue(e.validated_content, t, s);
1295
1299
  return n && !n?.isMissing;
1296
1300
  }), [s]), w = q(() => Array.from(u.files).map((e) => e.name).filter((e) => e.endsWith(".fasta") || e.endsWith(".fa") || e.endsWith(".fa.gz") || e.endsWith(".fasta.gz")), [u.files]), T = q(() => Array.from(u.files).map((e) => e.name).filter((e) => e.endsWith(".fastq") || e.endsWith(".fq") || e.endsWith(".fq.gz") || e.endsWith(".fastaq.gz")), [u.files]), E = G((e) => {
1297
1301
  let { dropDownOptions: t, dropDownValue: n, label: r, onChange: i } = e;
1298
- return /* @__PURE__ */ Q(ne, {
1302
+ return /* @__PURE__ */ Q(F, {
1299
1303
  freeSolo: !0,
1300
1304
  fullWidth: !0,
1301
1305
  onChange: (e, t) => {
1302
1306
  i(t), m(v.current), x();
1303
1307
  },
1304
1308
  options: t,
1305
- renderInput: (e) => /* @__PURE__ */ Q(se, {
1309
+ renderInput: (e) => /* @__PURE__ */ Q(ie, {
1306
1310
  ...e,
1307
1311
  label: r,
1308
1312
  size: "small"
@@ -1312,7 +1316,7 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
1312
1316
  });
1313
1317
  }, [m, x]), D = G((e) => {
1314
1318
  let t = s.cols[e.id], n = e.row.id, r = v.current?.[e.row.id]?.sequenceFileNames[t.id] || "";
1315
- return /* @__PURE__ */ Q(L, {
1319
+ return /* @__PURE__ */ Q(I, {
1316
1320
  sx: {
1317
1321
  alignItems: "center",
1318
1322
  display: "flex",
@@ -1335,7 +1339,7 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
1335
1339
  w
1336
1340
  ]), O = G((e) => {
1337
1341
  let t = s.cols[e.id], n = h.sequenceColumns.includes(t), r = e.row.id, i = v.current?.[r]?.readsFileNames?.[t.id]?.fwd || "", a = v.current?.[r]?.readsFileNames?.[t.id]?.rev || "";
1338
- return /* @__PURE__ */ $(L, {
1342
+ return /* @__PURE__ */ $(I, {
1339
1343
  sx: {
1340
1344
  alignItems: "center",
1341
1345
  display: "flex",
@@ -1368,7 +1372,7 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
1368
1372
  T
1369
1373
  ]), k = q(() => {
1370
1374
  let e = [];
1371
- e.push(Me.createReadableIndexColumn());
1375
+ e.push(je.createReadableIndexColumn());
1372
1376
  let t = [
1373
1377
  ...h.sampleIdColumns,
1374
1378
  ...h.sequenceColumns,
@@ -1440,26 +1444,26 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
1440
1444
  c,
1441
1445
  f
1442
1446
  ]);
1443
- return Ne({
1447
+ return Me({
1444
1448
  columns: k,
1445
1449
  createFiltersFromColumns: !0,
1446
1450
  rows: f,
1447
1451
  store: S
1448
- }), /* @__PURE__ */ $(L, {
1452
+ }), /* @__PURE__ */ $(I, {
1449
1453
  sx: {
1450
1454
  display: "grid",
1451
1455
  gridTemplateRows: "max-content auto max-content",
1452
1456
  height: "100%"
1453
1457
  },
1454
- children: [/* @__PURE__ */ Q(L, {
1458
+ children: [/* @__PURE__ */ Q(I, {
1455
1459
  sx: { paddingBottom: 1 },
1456
- children: /* @__PURE__ */ $(F, {
1460
+ children: /* @__PURE__ */ $(N, {
1457
1461
  severity: "info",
1458
- children: [/* @__PURE__ */ Q(I, { id: g }), /* @__PURE__ */ Q(L, { id: _ })]
1462
+ children: [/* @__PURE__ */ Q(P, { id: g }), /* @__PURE__ */ Q(I, { id: _ })]
1459
1463
  })
1460
- }), /* @__PURE__ */ $(fe, {
1464
+ }), /* @__PURE__ */ $(le, {
1461
1465
  store: S,
1462
- children: [/* @__PURE__ */ Q(ke, {
1466
+ children: [/* @__PURE__ */ Q(Oe, {
1463
1467
  font: n["gen-epix-ui-client-casedb"].lineList.font,
1464
1468
  rowHeight: 7
1465
1469
  }), /* @__PURE__ */ Q(Ve, {
@@ -1469,7 +1473,7 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
1469
1473
  })]
1470
1474
  });
1471
1475
  }, nt = () => {
1472
- let { t: e } = X(), t = ue(), n = W(p), r = l(n, (e) => e.completeCaseType), i = l(n, (e) => e.activeStep), a = l(n, (e) => e.stepOrder), o = q(() => ({
1476
+ let { t: e } = X(), t = se(), n = W(p), r = l(n, (e) => e.completeCaseType), i = l(n, (e) => e.activeStep), a = l(n, (e) => e.stepOrder), o = q(() => ({
1473
1477
  [f.CREATE_CASES]: e`Submit`,
1474
1478
  [f.MAP_COLUMNS]: e`Map columns`,
1475
1479
  [f.MAP_SEQUENCES]: e`Map sequences`,
@@ -1485,7 +1489,7 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
1485
1489
  o,
1486
1490
  a
1487
1491
  ]);
1488
- return /* @__PURE__ */ $(ve, {
1492
+ return /* @__PURE__ */ $(he, {
1489
1493
  sx: {
1490
1494
  display: "grid",
1491
1495
  gridTemplateRows: "max-content auto",
@@ -1493,11 +1497,11 @@ var Ve = ({ backLabel: e, onGoBackButtonClick: t, onProceedButtonClick: n, proce
1493
1497
  position: "relative",
1494
1498
  width: "100%"
1495
1499
  },
1496
- children: [/* @__PURE__ */ Q(re, { children: /* @__PURE__ */ Q(ye, {
1500
+ children: [/* @__PURE__ */ Q(te, { children: /* @__PURE__ */ Q(ge, {
1497
1501
  activeStep: String(i),
1498
1502
  steps: c,
1499
1503
  sx: { marginY: 2 }
1500
- }) }), /* @__PURE__ */ $(ve, {
1504
+ }) }), /* @__PURE__ */ $(he, {
1501
1505
  sx: {
1502
1506
  height: `calc(100% - ${t.spacing(4)})`,
1503
1507
  marginBottom: 2,