@zac-apps/helium 1.2.0 → 1.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +47 -0
- package/dist/index.js +1 -1
- package/package.json +22 -22
package/README.md
CHANGED
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
# ZAC Apps Helium Component
|
|
2
|
+
|
|
3
|
+
This is react component to manage and visualize the helium consumption of a set of NMR spectrometers. The productive use is showcased in a simple Next JS project ([Source](https://gitlab.rlp.net/zac/helium-app) | [Demo](https://zac.pages.gitlab.rlp.net/helium-app/)).
|
|
4
|
+
|
|
5
|
+
## Requirements
|
|
6
|
+
|
|
7
|
+
The component can be used in any React App framework and was tested with [Next JS](https://nextjs.org/).
|
|
8
|
+
|
|
9
|
+
## Spectrometer configuration
|
|
10
|
+
|
|
11
|
+
To provide the compoonent with the required data, the React App has to contain a file `/conf/heliumLookup.json`. A sample spectrometer configuration can be found [here](https://gitlab.rlp.net/zac/zac-helium-component/-/blob/main/conf/heliumLookup.json?ref_type=heads).
|
|
12
|
+
|
|
13
|
+
You can easily setup and download your own spectrometer configuration using the [ZAC Apps Helium Lookup Builder](https://liermann.pages.gitlab.rlp.net/helium-lookup-builder/). Simply place the JSON file obtained from there in your project as described above.
|
|
14
|
+
|
|
15
|
+
## Site environment variables
|
|
16
|
+
|
|
17
|
+
The component needs some variables about the site environment. These are read from `/conf/site.json`. A sample configuration file for this is provided [here](https://gitlab.rlp.net/zac/zac-helium-component/-/blob/main/conf/site.json?ref_type=heads).
|
|
18
|
+
|
|
19
|
+
## Installation
|
|
20
|
+
|
|
21
|
+
In your project, execute
|
|
22
|
+
|
|
23
|
+
```
|
|
24
|
+
npm install --save @zac-apps/helium
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
Then, import the component where you wish to use it:
|
|
28
|
+
|
|
29
|
+
```
|
|
30
|
+
import Helium from "@zac-apps/helium"
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
## Usage
|
|
34
|
+
|
|
35
|
+
The component is simply called using
|
|
36
|
+
|
|
37
|
+
```
|
|
38
|
+
<Helium />;
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
The component needs to know the site base path. This can either be provided by the environment variables as described above or as a prop:
|
|
42
|
+
|
|
43
|
+
```
|
|
44
|
+
<Helium basePath={env.basePath} />
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
with `env.basePath` being a string or string variable containing the React project's hosted base path. That means, if the app is hosted at `https://www.yourdomain.org/my-subfolder`, the `basePath` variable must be set to `/my-subfolder`.
|
package/dist/index.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zac-apps/helium",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.1",
|
|
4
4
|
"scripts": {
|
|
5
5
|
"rollup": "node_modules/rollup/dist/rollup.js",
|
|
6
6
|
"dev": "next dev",
|
|
@@ -28,39 +28,39 @@
|
|
|
28
28
|
"author": "ZAC",
|
|
29
29
|
"license": "CC-BY-SA-4.0",
|
|
30
30
|
"dependencies": {
|
|
31
|
-
"@mui/icons-material": "^5.15.
|
|
32
|
-
"@mui/material": "^5.15.
|
|
31
|
+
"@mui/icons-material": "^5.15.20",
|
|
32
|
+
"@mui/material": "^5.15.20",
|
|
33
33
|
"@zac-apps/commons": "^1.3.6",
|
|
34
34
|
"moment": "^2.30.1",
|
|
35
|
-
"recharts": "^2.12.
|
|
36
|
-
"use-immer": "^0.
|
|
35
|
+
"recharts": "^2.12.7",
|
|
36
|
+
"use-immer": "^0.10.0"
|
|
37
37
|
},
|
|
38
38
|
"devDependencies": {
|
|
39
|
-
"@babel/plugin-transform-runtime": "^7.24.
|
|
39
|
+
"@babel/plugin-transform-runtime": "^7.24.7",
|
|
40
40
|
"@emotion/react": "^11.11.4",
|
|
41
|
-
"@emotion/styled": "^11.11.
|
|
41
|
+
"@emotion/styled": "^11.11.5",
|
|
42
42
|
"@rollup/plugin-babel": "^6.0.4",
|
|
43
|
-
"@rollup/plugin-commonjs": "^
|
|
43
|
+
"@rollup/plugin-commonjs": "^26.0.1",
|
|
44
44
|
"@rollup/plugin-json": "^6.1.0",
|
|
45
45
|
"@rollup/plugin-node-resolve": "^15.2.3",
|
|
46
46
|
"@semantic-release/git": "^10.0.1",
|
|
47
|
-
"@semantic-release/gitlab": "^13.0
|
|
48
|
-
"@semantic-release/npm": "^12.0.
|
|
49
|
-
"@storybook/addon-essentials": "^8.
|
|
50
|
-
"@storybook/addon-interactions": "^8.
|
|
51
|
-
"@storybook/addon-links": "^8.
|
|
52
|
-
"@storybook/addon-onboarding": "^8.
|
|
53
|
-
"@storybook/blocks": "^8.
|
|
54
|
-
"@storybook/nextjs": "^8.
|
|
55
|
-
"@storybook/react": "^8.
|
|
56
|
-
"@storybook/test": "^8.
|
|
47
|
+
"@semantic-release/gitlab": "^13.1.0",
|
|
48
|
+
"@semantic-release/npm": "^12.0.1",
|
|
49
|
+
"@storybook/addon-essentials": "^8.1.10",
|
|
50
|
+
"@storybook/addon-interactions": "^8.1.10",
|
|
51
|
+
"@storybook/addon-links": "^8.1.10",
|
|
52
|
+
"@storybook/addon-onboarding": "^8.1.10",
|
|
53
|
+
"@storybook/blocks": "^8.1.10",
|
|
54
|
+
"@storybook/nextjs": "^8.1.10",
|
|
55
|
+
"@storybook/react": "^8.1.10",
|
|
56
|
+
"@storybook/test": "^8.1.10",
|
|
57
57
|
"babel-loader": "^9.1.3",
|
|
58
58
|
"eslint": "^8",
|
|
59
|
-
"eslint-config-next": "14.
|
|
59
|
+
"eslint-config-next": "14.2.4",
|
|
60
60
|
"eslint-plugin-storybook": "^0.8.0",
|
|
61
|
-
"rollup": "^4.
|
|
62
|
-
"semantic-release": "^
|
|
63
|
-
"storybook": "^8.
|
|
61
|
+
"rollup": "^4.18.0",
|
|
62
|
+
"semantic-release": "^24.0.0",
|
|
63
|
+
"storybook": "^8.1.10"
|
|
64
64
|
},
|
|
65
65
|
"peerDependencies": {
|
|
66
66
|
"next": "^14.0.4",
|