@opencloning/ui 1.4.8 → 1.4.10
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/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,25 @@
|
|
|
1
1
|
# @opencloning/ui
|
|
2
2
|
|
|
3
|
+
## 1.4.10
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#642](https://github.com/manulera/OpenCloning_frontend/pull/642) [`3028e98`](https://github.com/manulera/OpenCloning_frontend/commit/3028e98b60be89288327cc1b6dac87cb2479a3c7) Thanks [@manulera](https://github.com/manulera)! - When downloading from assembler, if name is too long change to id_construct
|
|
8
|
+
|
|
9
|
+
- Updated dependencies []:
|
|
10
|
+
- @opencloning/store@1.4.10
|
|
11
|
+
- @opencloning/utils@1.4.10
|
|
12
|
+
|
|
13
|
+
## 1.4.9
|
|
14
|
+
|
|
15
|
+
### Patch Changes
|
|
16
|
+
|
|
17
|
+
- [#640](https://github.com/manulera/OpenCloning_frontend/pull/640) [`2a8015b`](https://github.com/manulera/OpenCloning_frontend/commit/2a8015b63534c56dc7a7ae38b5fab7f14db1262d) Thanks [@manulera](https://github.com/manulera)! - Improve width of assembler plasmids dropdowns
|
|
18
|
+
|
|
19
|
+
- Updated dependencies []:
|
|
20
|
+
- @opencloning/store@1.4.9
|
|
21
|
+
- @opencloning/utils@1.4.9
|
|
22
|
+
|
|
3
23
|
## 1.4.8
|
|
4
24
|
|
|
5
25
|
### Patch Changes
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@opencloning/ui",
|
|
3
|
-
"version": "1.4.
|
|
3
|
+
"version": "1.4.10",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "./src/index.js",
|
|
6
6
|
"scripts": {
|
|
@@ -25,8 +25,8 @@
|
|
|
25
25
|
"@emotion/styled": "^11.14.0",
|
|
26
26
|
"@mui/icons-material": "^5.15.17",
|
|
27
27
|
"@mui/material": "^5.15.17",
|
|
28
|
-
"@opencloning/store": "1.4.
|
|
29
|
-
"@opencloning/utils": "1.4.
|
|
28
|
+
"@opencloning/store": "1.4.10",
|
|
29
|
+
"@opencloning/utils": "1.4.10",
|
|
30
30
|
"@teselagen/bio-parsers": "^0.4.34",
|
|
31
31
|
"@teselagen/ove": "^0.8.34",
|
|
32
32
|
"@teselagen/range-utils": "^0.3.20",
|
|
@@ -105,6 +105,11 @@ function AssemblerBox({ item, index, setCategory, setId, categories, plasmids, a
|
|
|
105
105
|
options={allowedPlasmids.map((item) => item.id)}
|
|
106
106
|
getOptionLabel={(id) => formatItemName(plasmids.find((d) => d.id === id))}
|
|
107
107
|
renderInput={(params) => <TextField {...params} label="Plasmids" />}
|
|
108
|
+
componentsProps={{
|
|
109
|
+
popper: {
|
|
110
|
+
sx: { minWidth: 'max-content' },
|
|
111
|
+
},
|
|
112
|
+
}}
|
|
108
113
|
renderOption={(props, option) => {
|
|
109
114
|
const { key, ...restProps } = props
|
|
110
115
|
const plasmid = plasmids.find((d) => d.id === option)
|
|
@@ -168,7 +168,10 @@ export function getFilesToExportFromAssembler({requestedAssemblies, expandedAsse
|
|
|
168
168
|
}
|
|
169
169
|
|
|
170
170
|
for (let i = 0; i < requestedAssemblies.length; i++) {
|
|
171
|
-
|
|
171
|
+
let name = `${String(i + 1).padStart(3, '0')}_${assemblyNames[i].slice(1).join('+')}`;
|
|
172
|
+
if (name.length > 255) {
|
|
173
|
+
name = `${String(i + 1).padStart(3, '0')}_construct`;
|
|
174
|
+
}
|
|
172
175
|
const requestedAssembly = requestedAssemblies[i];
|
|
173
176
|
const jsonContent = formatStateForJsonExport({...requestedAssembly, appInfo});
|
|
174
177
|
files2Export.push({
|
|
@@ -285,8 +285,8 @@ const dummyData = {
|
|
|
285
285
|
|
|
286
286
|
|
|
287
287
|
|
|
288
|
-
describe('
|
|
289
|
-
it('returns
|
|
288
|
+
describe('getFilesToExportFromAssembler', () => {
|
|
289
|
+
it('returns the correct files', () => {
|
|
290
290
|
const files = getFilesToExportFromAssembler(dummyData);
|
|
291
291
|
expect(files[0].name).toBe('assemblies.tsv');
|
|
292
292
|
expect(files[0].content).toBe('Assembly\tCategory 1\tCategory 2\tCategory 3\n1\tp1\tp5\tp7\n2\tp1\tp2\tp3');
|
|
@@ -310,4 +310,15 @@ describe('getZipFileFromAssemblies', () => {
|
|
|
310
310
|
|
|
311
311
|
|
|
312
312
|
})
|
|
313
|
+
it('changes name if file names are too long', () => {
|
|
314
|
+
const dummyData2 = {
|
|
315
|
+
...dummyData,
|
|
316
|
+
plasmids: dummyData.plasmids.map(plasmid => ({...plasmid, plasmid_name: 'p1'.repeat(100)})),
|
|
317
|
+
}
|
|
318
|
+
const files = getFilesToExportFromAssembler(dummyData2);
|
|
319
|
+
expect(files[2].name).toBe('001_construct.json');
|
|
320
|
+
expect(files[3].name).toBe('001_construct.gbk');
|
|
321
|
+
expect(files[4].name).toBe('002_construct.json');
|
|
322
|
+
expect(files[5].name).toBe('002_construct.gbk');
|
|
323
|
+
})
|
|
313
324
|
})
|
package/src/version.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
// Version placeholder - replaced at publish time via prepack script
|
|
2
|
-
export const version = "1.4.
|
|
2
|
+
export const version = "1.4.10";
|