react-msaview 8.4.0 → 8.4.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/dist/version.d.ts CHANGED
@@ -1 +1 @@
1
- export declare const version = "8.4.0";
1
+ export declare const version = "8.4.1";
package/dist/version.js CHANGED
@@ -1,2 +1,2 @@
1
- export const version = '8.4.0';
1
+ export const version = '8.4.1';
2
2
  //# sourceMappingURL=version.js.map
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "react-msaview",
3
3
  "author": "Colin",
4
- "version": "8.4.0",
4
+ "version": "8.4.1",
5
5
  "license": "MIT",
6
6
  "type": "module",
7
7
  "repository": {
@@ -37,11 +37,11 @@
37
37
  "react-dom": ">=16.8.0"
38
38
  },
39
39
  "devDependencies": {
40
- "@jbrowse/core": "file:vendor-jbrowse/jbrowse-core.tgz",
41
- "@jbrowse/mobx-state-tree": "^6.5.1",
40
+ "@jbrowse/core": "^5.0.0-beta.9",
41
+ "@jbrowse/mobx-state-tree": "^6.6.1",
42
42
  "@mui/icons-material": "^9.4.0",
43
43
  "@mui/material": "^9.4.0",
44
- "@types/node": "^26.5.1",
44
+ "@types/node": "^26.6.2",
45
45
  "esbuild": "^0.28.2",
46
46
  "mobx": "^7.0.3",
47
47
  "mobx-react": "^10.0.2",
@@ -50,10 +50,10 @@
50
50
  },
51
51
  "dependencies": {
52
52
  "@gmod/newick": "^1.0.3",
53
- "@jbrowse/svgcanvas": "8.4.0",
53
+ "@jbrowse/svgcanvas": "8.4.1",
54
54
  "colord": "^2.10.0",
55
55
  "flatbush": "^4.6.2",
56
- "msa-parsers": "8.4.0"
56
+ "msa-parsers": "8.4.1"
57
57
  },
58
58
  "scripts": {
59
59
  "clean": "rimraf dist bundle",
@@ -6,9 +6,26 @@ import { observer } from 'mobx-react'
6
6
  import { findableRowNames, goTo, rowNameSuggestions } from './goTo.ts'
7
7
 
8
8
  import type { MsaViewModel } from '../../model.ts'
9
+ import type { AutocompleteRenderInputParams } from '@mui/material'
9
10
 
10
11
  const label = 'Go to row or column'
11
12
 
13
+ // MUI 9 hands renderInput `slotProps`; MUI 7, which every released JBrowse host
14
+ // serves, hands it `inputProps` and no `slotProps` at all
15
+ export function labelledInput(params: AutocompleteRenderInputParams) {
16
+ const { slotProps, inputProps } = params as Partial<
17
+ AutocompleteRenderInputParams & { inputProps: object }
18
+ >
19
+ return slotProps
20
+ ? {
21
+ slotProps: {
22
+ ...slotProps,
23
+ htmlInput: { ...slotProps.htmlInput, 'aria-label': label },
24
+ },
25
+ }
26
+ : { inputProps: { ...inputProps, 'aria-label': label } }
27
+ }
28
+
12
29
  const GoToBox = observer(function ({ model }: { model: MsaViewModel }) {
13
30
  const [missed, setMissed] = useState(false)
14
31
  const names = findableRowNames(model)
@@ -37,10 +54,7 @@ const GoToBox = observer(function ({ model }: { model: MsaViewModel }) {
37
54
  error={missed}
38
55
  placeholder={label}
39
56
  title="A row name, a column number, or name:residue"
40
- slotProps={{
41
- ...params.slotProps,
42
- htmlInput: { ...params.slotProps.htmlInput, 'aria-label': label },
43
- }}
57
+ {...labelledInput(params)}
44
58
  />
45
59
  )}
46
60
  />
package/src/model.ts CHANGED
@@ -1588,28 +1588,28 @@ function stateModelFactory({
1588
1588
  * #action
1589
1589
  */
1590
1590
  setMSAFilehandle(msaFilehandle?: FileLocationType) {
1591
- self.msaFilehandle = msaFilehandle
1591
+ self.msaFilehandle = cast(msaFilehandle)
1592
1592
  },
1593
1593
 
1594
1594
  /**
1595
1595
  * #action
1596
1596
  */
1597
1597
  setTreeFilehandle(treeFilehandle?: FileLocationType) {
1598
- self.treeFilehandle = treeFilehandle
1598
+ self.treeFilehandle = cast(treeFilehandle)
1599
1599
  },
1600
1600
 
1601
1601
  /**
1602
1602
  * #action
1603
1603
  */
1604
1604
  setTreeMetadataFilehandle(treeMetadataFilehandle?: FileLocationType) {
1605
- self.treeMetadataFilehandle = treeMetadataFilehandle
1605
+ self.treeMetadataFilehandle = cast(treeMetadataFilehandle)
1606
1606
  },
1607
1607
 
1608
1608
  /**
1609
1609
  * #action
1610
1610
  */
1611
1611
  setGFFFilehandle(gffFilehandle?: FileLocationType) {
1612
- self.gffFilehandle = gffFilehandle
1612
+ self.gffFilehandle = cast(gffFilehandle)
1613
1613
  },
1614
1614
 
1615
1615
  /**
package/src/version.ts CHANGED
@@ -1 +1 @@
1
- export const version = '8.4.0'
1
+ export const version = '8.4.1'