react-component-instance 0.0.6 → 0.0.7

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-component-instance",
3
- "version": "0.0.6",
3
+ "version": "0.0.7",
4
4
  "description": "Get a React class component instance from its DOM Element",
5
5
  "keywords": [
6
6
  "react",
@@ -41,7 +41,6 @@
41
41
  "@testing-library/react": "^16.2.0",
42
42
  "@types/debug": "^4.1.12",
43
43
  "@types/jest": "^29.5.14",
44
- "@types/prop-types": "^15.7.14",
45
44
  "@types/react": "^19.0.11",
46
45
  "core-js": "^3.41.0",
47
46
  "eslint": "^9.22.0",
@@ -21,13 +21,15 @@ export function getContainerFiberNodeFrom (container) {
21
21
  }
22
22
 
23
23
  /**
24
- * @param {{ container: Element }} component
25
- * @returns {Element}
24
+ * @param {{ container: { firstElementChild: Element | null } }} component
25
+ * @returns {Element | null}
26
26
  */
27
27
  export function getComponentElement ({
28
- container
28
+ container: {
29
+ firstElementChild: element
30
+ }
29
31
  }) {
30
- return container
32
+ return element
31
33
  }
32
34
 
33
35
  /**