@rivm-loculus-tools/common-frontend 0.4.0 → 0.5.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 (47) hide show
  1. package/dist/_chunks/EmotionCacheService.js +2 -4
  2. package/dist/_chunks/EmotionCacheService.js.map +1 -1
  3. package/dist/_chunks/decorate.js +1 -2
  4. package/dist/_chunks/react.js +2 -3
  5. package/dist/_chunks/react.js.map +1 -1
  6. package/dist/classes/services/FastaDataEventBusService/index.js +1 -2
  7. package/dist/components/SearchBar/index.js +1 -2
  8. package/dist/components/app/App/index.js +38 -44
  9. package/dist/components/app/App/index.js.map +1 -1
  10. package/dist/components/fasta/FastaDataImportDialog/index.js +1 -2
  11. package/dist/components/fasta/FastaDataImportDialogLoader/index.js +1 -2
  12. package/dist/components/fasta/FastaNotLoaded/index.js +1 -2
  13. package/dist/components/fasta/FastaPageHeaderCenterComponent/index.js +1 -2
  14. package/dist/components/fasta/FastaPageHeaderImportButton/index.js +1 -2
  15. package/dist/components/fasta/FastaPageHeaderResetButton/index.js +1 -2
  16. package/dist/components/ui/ButtonWithMenu/index.js +1 -2
  17. package/dist/components/ui/GenericErrorMessage/index.js +1 -2
  18. package/dist/components/ui/I18nWrapper/index.js +1 -2
  19. package/dist/components/ui/PageCommon/index.js +1 -2
  20. package/dist/components/ui/PageCommonDrawer/index.js +1 -2
  21. package/dist/components/ui/PageCommonHeader/index.js +1 -2
  22. package/dist/constants/config.constants.js +1 -2
  23. package/dist/constants/page.constants.js +1 -2
  24. package/dist/context/pageCommonContext/index.js +1 -2
  25. package/dist/hooks/useConfig/index.js +3 -4
  26. package/dist/hooks/useConfig/index.js.map +1 -1
  27. package/dist/hooks/useUpdateDocumentTitle/index.js +1 -2
  28. package/dist/models/fasta.models.js +1 -2
  29. package/dist/models/fasta.models.js.map +1 -1
  30. package/dist/pages/ErrorPage/index.js +1 -2
  31. package/dist/stores/fastaDataStore/index.js +1 -2
  32. package/dist/theme/index.js +1 -2
  33. package/dist/utils/DependencyContainerUtil/index.js +1 -2
  34. package/dist/utils/DownloadUtil/index.js +1 -2
  35. package/dist/utils/ErrorUtil/index.js +1 -2
  36. package/dist/utils/ExportUtil/index.js +1 -2
  37. package/dist/utils/FastaUtil/index.js +1 -2
  38. package/dist/utils/MetaDataUtil/index.js +1 -2
  39. package/dist/utils/StandardConfigUtil/index.js +1 -2
  40. package/dist/utils/UrlUtil/index.js +1 -2
  41. package/package.json +16 -20
  42. package/dist/context/commonConfigContext/CommonConfigContext.d.ts +0 -9
  43. package/dist/context/commonConfigContext/CommonConfigContextProvider.d.ts +0 -6
  44. package/dist/context/commonConfigContext/index.d.ts +0 -3
  45. package/dist/context/commonConfigContext/index.js +0 -34
  46. package/dist/context/commonConfigContext/index.js.map +0 -1
  47. package/dist/context/commonConfigContext/useCommonConfigContext.d.ts +0 -3
@@ -3,7 +3,7 @@ import { container as i } from "tsyringe";
3
3
  import { WindowService as a } from "@gen-epix/ui-core/classes/services/WindowService";
4
4
  import { DevicePixelRatioService as o } from "@gen-epix/ui-core/classes/services/DevicePixelRatioService";
5
5
  import { KeyboardShortcutService as s } from "@gen-epix/ui-core/classes/services/KeyboardShortcutService";
6
- //#region src/utils/DependencyContainerUtil/DependencyContainerUtil.ts
6
+ // src/utils/DependencyContainerUtil/DependencyContainerUtil.ts
7
7
  var c = class {
8
8
  static createContainer() {
9
9
  return i.registerInstance(r, a.getInstance()), i.registerInstance(t, o.getInstance()), i.registerInstance(n, s.getInstance()), i;
@@ -12,7 +12,6 @@ var c = class {
12
12
  return t.resolve(e);
13
13
  }
14
14
  };
15
- //#endregion
16
15
  export { c as DependencyContainerUtil };
17
16
 
18
17
  //# sourceMappingURL=index.js.map
@@ -1,10 +1,9 @@
1
- //#region src/utils/DownloadUtil/DownloadUtil.ts
1
+ // src/utils/DownloadUtil/DownloadUtil.ts
2
2
  var e = class {
3
3
  static datasetFilename(e) {
4
4
  return `${e.trim().replace(/\.[^.]+$/, "").replace(/[^a-zA-Z0-9._-]+/g, "_").replace(/^\.+|\.+$/g, "").slice(0, 80) || "alignment"}.fasta`;
5
5
  }
6
6
  };
7
- //#endregion
8
7
  export { e as DownloadUtil };
9
8
 
10
9
  //# sourceMappingURL=index.js.map
@@ -1,10 +1,9 @@
1
- //#region src/utils/ErrorUtil/ErrorUtil.ts
1
+ // src/utils/ErrorUtil/ErrorUtil.ts
2
2
  var e = class {
3
3
  static getErrorMessage(e, t) {
4
4
  return e instanceof Error ? e.message : t;
5
5
  }
6
6
  };
7
- //#endregion
8
7
  export { e as ErrorUtil };
9
8
 
10
9
  //# sourceMappingURL=index.js.map
@@ -1,5 +1,5 @@
1
1
  import { DownloadUtil as e } from "@gen-epix/ui-core/utils/DownloadUtil";
2
- //#region src/utils/ExportUtil/ExportUtil.ts
2
+ // src/utils/ExportUtil/ExportUtil.ts
3
3
  var t = class {
4
4
  static downloadCanvasAsImage(t, n, r = "phylogenetic_tree") {
5
5
  if (!t) {
@@ -36,7 +36,6 @@ var t = class {
36
36
  e.createDownloadUrl(i, n), URL.revokeObjectURL(i);
37
37
  }
38
38
  };
39
- //#endregion
40
39
  export { t as ExportUtil };
41
40
 
42
41
  //# sourceMappingURL=index.js.map
@@ -1,4 +1,4 @@
1
- //#region src/utils/FastaUtil/FastaUtil.ts
1
+ // src/utils/FastaUtil/FastaUtil.ts
2
2
  var e = class e {
3
3
  static parseFasta(t) {
4
4
  if (!t?.trim()) return e.createErrorResult("The FASTA input is empty.");
@@ -50,7 +50,6 @@ var e = class e {
50
50
  };
51
51
  }
52
52
  };
53
- //#endregion
54
53
  export { e as FastaUtil };
55
54
 
56
55
  //# sourceMappingURL=index.js.map
@@ -1,4 +1,4 @@
1
- //#region src/utils/MetaDataUtil/MetaDataUtil.ts
1
+ // src/utils/MetaDataUtil/MetaDataUtil.ts
2
2
  var e = class e {
3
3
  static findBestMatchingColumn = (t, n, r) => {
4
4
  let i = e.getMatchCounts(t, n, r), a = null, o = -1;
@@ -127,7 +127,6 @@ var e = class e {
127
127
  };
128
128
  };
129
129
  };
130
- //#endregion
131
130
  export { e as MetaDataUtil };
132
131
 
133
132
  //# sourceMappingURL=index.js.map
@@ -1,5 +1,5 @@
1
1
  import { WindowService as e } from "@gen-epix/ui-core/classes/services/WindowService";
2
- //#region src/utils/StandardConfigUtil/StandardConfigUtil.ts
2
+ // src/utils/StandardConfigUtil/StandardConfigUtil.ts
3
3
  var t = class {
4
4
  static createConfig() {
5
5
  return {
@@ -12,7 +12,6 @@ var t = class {
12
12
  };
13
13
  }
14
14
  };
15
- //#endregion
16
15
  export { t as StandardConfigUtil };
17
16
 
18
17
  //# sourceMappingURL=index.js.map
@@ -1,6 +1,6 @@
1
1
  import { WINDOW_SERVICE_TOKEN as e } from "../../constants/config.constants.js";
2
2
  import { container as t } from "tsyringe";
3
- //#region src/utils/UrlUtil/UrlUtil.ts
3
+ // src/utils/UrlUtil/UrlUtil.ts
4
4
  var n = class {
5
5
  static clearSearchParams() {
6
6
  let n = new URL(t.resolve(e).window.location.href);
@@ -25,7 +25,6 @@ var n = class {
25
25
  return t.href;
26
26
  }
27
27
  };
28
- //#endregion
29
28
  export { n as UrlUtil };
30
29
 
31
30
  //# sourceMappingURL=index.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rivm-loculus-tools/common-frontend",
3
- "version": "0.4.0",
3
+ "version": "0.5.0",
4
4
  "license": "EUPL-1.2",
5
5
  "repository": {
6
6
  "type": "git",
@@ -11,9 +11,9 @@
11
11
  "@emotion/cache": "*",
12
12
  "@emotion/react": "*",
13
13
  "@emotion/styled": "*",
14
- "@gen-epix/ui-core-components": "^4.5.0",
15
- "@gen-epix/ui-core-form": "^4.4.1",
16
- "@gen-epix/ui-core": "^3.9.1",
14
+ "@gen-epix/ui-core-components": "^4.6.0",
15
+ "@gen-epix/ui-core-form": "^4.5.0",
16
+ "@gen-epix/ui-core": "^3.10.0",
17
17
  "@mui/icons-material": "*",
18
18
  "@mui/material": "*",
19
19
  "@mui/styled-engine": "*",
@@ -29,39 +29,39 @@
29
29
  },
30
30
  "dependencies": {
31
31
  "lodash": "4.18.1",
32
- "zustand": "5.0.15"
32
+ "zustand": "5.0.16"
33
33
  },
34
34
  "devDependencies": {
35
35
  "@emotion/cache": "11.14.0",
36
36
  "@emotion/react": "11.14.0",
37
37
  "@emotion/styled": "11.14.1",
38
38
  "@gen-epix/eslint-config": "0.8.0",
39
- "@gen-epix/ui-core-components": "4.5.0",
40
- "@gen-epix/ui-core-form": "4.4.1",
41
- "@gen-epix/ui-core": "3.9.1",
39
+ "@gen-epix/ui-core-components": "4.6.0",
40
+ "@gen-epix/ui-core-form": "4.5.0",
41
+ "@gen-epix/ui-core": "3.10.0",
42
42
  "@mui/icons-material": "9.5.0",
43
43
  "@mui/material": "9.5.0",
44
44
  "@mui/styled-engine": "9.5.0",
45
45
  "@mui/system": "9.5.0",
46
46
  "@mui/utils": "9.5.0",
47
- "@types/lodash": "4.17.26",
47
+ "@types/lodash": "4.17.27",
48
48
  "@types/node": "26.6.5",
49
49
  "@types/react-dom": "19.3.0",
50
50
  "@types/react": "19.3.0",
51
51
  "@vitejs/plugin-react": "6.1.2",
52
- "eslint": "10.12.0",
53
- "i18next": "26.4.4",
54
- "react-dom": "19.3.0",
52
+ "eslint": "10.13.0",
53
+ "i18next": "26.5.11",
54
+ "react-dom": "19.3.1",
55
55
  "react-error-boundary": "6.1.6",
56
- "react-hook-form": "7.90.0",
57
- "react-i18next": "17.0.16",
58
- "react": "19.3.0",
56
+ "react-hook-form": "7.91.0",
57
+ "react-i18next": "17.1.9",
58
+ "react": "19.3.1",
59
59
  "reflect-metadata": "0.2.2",
60
60
  "tsyringe": "4.10.0",
61
61
  "typescript": "6.0.3",
62
62
  "vite-plugin-dts": "5.1.2",
63
63
  "vite-plugin-static-copy": "4.1.1",
64
- "vite": "8.3.4"
64
+ "vite": "8.3.5"
65
65
  },
66
66
  "files": [
67
67
  "dist"
@@ -139,10 +139,6 @@
139
139
  "types": "./dist/constants/page.constants.d.ts",
140
140
  "import": "./dist/constants/page.constants.js"
141
141
  },
142
- "./context/commonConfigContext": {
143
- "types": "./dist/context/commonConfigContext/index.d.ts",
144
- "import": "./dist/context/commonConfigContext/index.js"
145
- },
146
142
  "./context/pageCommonContext": {
147
143
  "types": "./dist/context/pageCommonContext/index.d.ts",
148
144
  "import": "./dist/context/pageCommonContext/index.js"
@@ -1,9 +0,0 @@
1
- import { CoreComponentsConfig } from '@gen-epix/ui-core-components/context/CoreComponentsConfigContext';
2
- import { DependencyContainer } from 'tsyringe';
3
- import { ConfigBase } from '../../models/config.models';
4
- export type CommonConfig<TConfig extends ConfigBase = ConfigBase> = {
5
- config: TConfig;
6
- container: DependencyContainer;
7
- genEpixCoreComponentsConfig: CoreComponentsConfig;
8
- };
9
- export declare const CommonConfigContext: import('react').Context<CommonConfig<ConfigBase> | null>;
@@ -1,6 +0,0 @@
1
- import { PropsWithChildren } from 'react';
2
- import { DependencyContainer } from 'tsyringe';
3
- export type CommonConfigContextProviderProps = PropsWithChildren<{
4
- readonly container: DependencyContainer;
5
- }>;
6
- export declare const CommonConfigContextProvider: (props: CommonConfigContextProviderProps) => import('react').JSX.Element;
@@ -1,3 +0,0 @@
1
- export * from './CommonConfigContext';
2
- export * from './CommonConfigContextProvider';
3
- export * from './useCommonConfigContext';
@@ -1,34 +0,0 @@
1
- import { DependencyContainerUtil as e } from "../../utils/DependencyContainerUtil/index.js";
2
- import { jsx as t } from "react/jsx-runtime";
3
- import { createContext as n, use as r, useMemo as i } from "react";
4
- import { CoreComponentsConfigContext as a } from "@gen-epix/ui-core-components/context/CoreComponentsConfigContext";
5
- //#region src/context/commonConfigContext/CommonConfigContext.tsx
6
- var o = n(null), s = (n) => {
7
- let { children: r, container: s } = n, c = e.resolveConfig(s), l = i(() => ({ spinner: {
8
- defaultCircularProgressSize: c.spinner.DEFAULT_CIRCULAR_PROGRESS_SIZE,
9
- defaultTakingLongerTimeoutMs: c.spinner.DEFAULT_TAKING_LONGER_TIMEOUT_MS
10
- } }), [c.spinner]), u = i(() => ({
11
- config: c,
12
- container: s,
13
- genEpixCoreComponentsConfig: l
14
- }), [
15
- c,
16
- s,
17
- l
18
- ]);
19
- return /* @__PURE__ */ t(a, {
20
- value: l,
21
- children: /* @__PURE__ */ t(o, {
22
- value: u,
23
- children: r
24
- })
25
- });
26
- }, c = () => {
27
- let e = r(o);
28
- if (!e) throw Error("CommonConfigContext is not available");
29
- return e;
30
- };
31
- //#endregion
32
- export { o as CommonConfigContext, s as CommonConfigContextProvider, c as useCommonConfigContext };
33
-
34
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","names":["CommonConfigContext","createContext","CommonConfigContextProvider","props","config","DependencyContainerUtil","container","genEpixCoreComponentsConfig","useMemo","CommonConfig","CoreComponentsConfigContext","useCommonConfigContext","use"],"sources":["../../../src/context/commonConfigContext/CommonConfigContext.tsx","../../../src/context/commonConfigContext/CommonConfigContextProvider.tsx","../../../src/context/commonConfigContext/useCommonConfigContext.tsx"],"sourcesContent":["import type { CoreComponentsConfig } from '@gen-epix/ui-core-components/context/CoreComponentsConfigContext';\nimport { createContext } from 'react';\nimport type { DependencyContainer } from 'tsyringe';\n\nimport type { ConfigBase } from '../../models/config.models';\n\nexport type CommonConfig<TConfig extends ConfigBase = ConfigBase> = {\n config: TConfig;\n container: DependencyContainer;\n genEpixCoreComponentsConfig: CoreComponentsConfig;\n};\n\nexport const CommonConfigContext = createContext<CommonConfig | null>(null);\n","import { useMemo } from 'react';\nimport type { PropsWithChildren } from 'react';\nimport { CoreComponentsConfigContext } from '@gen-epix/ui-core-components/context/CoreComponentsConfigContext';\nimport type { DependencyContainer } from 'tsyringe';\n\nimport { DependencyContainerUtil } from '../../utils/DependencyContainerUtil';\nimport type { ConfigBase } from '../../models/config.models';\n\nimport type { CommonConfig } from './CommonConfigContext';\nimport { CommonConfigContext } from './CommonConfigContext';\n\n\nexport type CommonConfigContextProviderProps = PropsWithChildren<{\n readonly container: DependencyContainer;\n}>;\n\nexport const CommonConfigContextProvider = (\n props: CommonConfigContextProviderProps,\n) => {\n const { children, container } = props;\n const config = DependencyContainerUtil.resolveConfig<ConfigBase>(container);\n const genEpixCoreComponentsConfig = useMemo<CommonConfig['genEpixCoreComponentsConfig']>(() => ({\n spinner: {\n defaultCircularProgressSize: config.spinner.DEFAULT_CIRCULAR_PROGRESS_SIZE!,\n defaultTakingLongerTimeoutMs: config.spinner.DEFAULT_TAKING_LONGER_TIMEOUT_MS,\n },\n }), [config.spinner]);\n const CommonConfig = useMemo(() => ({ config, container, genEpixCoreComponentsConfig }), [config, container, genEpixCoreComponentsConfig]);\n\n return (\n <CoreComponentsConfigContext value={genEpixCoreComponentsConfig}>\n <CommonConfigContext value={CommonConfig}>\n {children}\n </CommonConfigContext>\n </CoreComponentsConfigContext>\n );\n};\n","import { use } from 'react';\n\nimport type { ConfigBase } from '../../models/config.models';\n\nimport type { CommonConfig } from './CommonConfigContext';\nimport { CommonConfigContext } from './CommonConfigContext';\n\nexport const useCommonConfigContext = <TConfig extends ConfigBase = ConfigBase>(): CommonConfig<TConfig> => {\n const config = use(CommonConfigContext);\n if (!config) {\n throw new Error('CommonConfigContext is not available');\n }\n return config as CommonConfig<TConfig>;\n};\n"],"mappings":";;;;;AAYA,IAAaA,IAAsBC,EAAmC,IAAI,GCI7DC,KACX,MACG;CACH,IAAM,EAAE,aAAU,iBAAcC,GAC1BC,IAASC,EAAwB,cAA0BC,CAAS,GACpEC,IAA8BC,SAA4D,EAC9F,SAAS;EACP,6BAA6BJ,EAAO,QAAQ;EAC5C,8BAA8BA,EAAO,QAAQ;CAC/C,EACF,IAAI,CAACA,EAAO,OAAO,CAAC,GACdK,IAAeD,SAAe;EAAE;EAAQ;EAAW;CAA4B,IAAI;EAACJ;EAAQE;EAAWC;CAA2B,CAAC;CAEzI,OACE,kBAACG,GAAD;EAA6B,OAAOH;EAClC,UAAA,kBAACP,GAAD;GAAqB,OAAOS;GACzB;EACkB,CAAA;CACM,CAAA;AAEjC,GC7BaE,UAA+F;CAC1G,IAAMP,IAASQ,EAAIZ,CAAmB;CACtC,IAAI,CAACI,GACH,MAAU,MAAM,sCAAsC;CAExD,OAAOA;AACT"}
@@ -1,3 +0,0 @@
1
- import { ConfigBase } from '../../models/config.models';
2
- import { CommonConfig } from './CommonConfigContext';
3
- export declare const useCommonConfigContext: <TConfig extends ConfigBase = ConfigBase>() => CommonConfig<TConfig>;