@primer/react 38.42.0 → 38.42.1-rc.26719e9c2

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,11 @@
1
1
  # @primer/react
2
2
 
3
+ ## 38.42.1
4
+
5
+ ### Patch Changes
6
+
7
+ - [#8524](https://github.com/primer/react/pull/8524) [`0d5607c`](https://github.com/primer/react/commit/0d5607c3b29ab090a0a97d1532fdc3a066a37d3d) Thanks [@tay1orjones](https://github.com/tay1orjones)! - TreeView: Prevent typeahead errors and focus changes when typing in nested controls.
8
+
3
9
  ## 38.42.0
4
10
 
5
11
  ### Minor Changes
@@ -52,6 +52,7 @@ function useTypeahead(t0) {
52
52
  if (!containerRef.current) return;
53
53
  const container = containerRef.current;
54
54
  const onKeyDown = function onKeyDown(event) {
55
+ if (!(event.target instanceof HTMLElement) || event.target.getAttribute("role") !== "treeitem") return;
55
56
  if (!event.key || event.key.length > 1 || event.key === " ") return;
56
57
  if (event.ctrlKey || event.altKey || event.metaKey) return;
57
58
  searchValue.current = searchValue.current + event.key;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@primer/react",
3
3
  "type": "module",
4
- "version": "38.42.0",
4
+ "version": "38.42.1-rc.26719e9c2",
5
5
  "description": "An implementation of GitHub's Primer Design System using React",
6
6
  "main": "./dist/index.js",
7
7
  "module": "./dist/index.js",