Skip to content

Commit

Permalink
Merge pull request #111 from FrameMuse/89-modalcomponent-type-enhance…
Browse files Browse the repository at this point in the history
…ment-hasnt-been-applied

`ModalComponent` type enhancement hasn't been applied
  • Loading branch information
FrameMuse authored Apr 17, 2023
2 parents 2f8756b + 3ab18ff commit fecbf32
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
4 changes: 2 additions & 2 deletions coverage/clover.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<coverage generated="1680075298485" clover="3.2.0">
<project timestamp="1680075298486" name="All files">
<coverage generated="1681730354787" clover="3.2.0">
<project timestamp="1681730354787" name="All files">
<metrics statements="109" coveredstatements="106" conditionals="55" coveredconditionals="47" methods="38" coveredmethods="37" elements="202" coveredelements="190" complexity="0" loc="109" ncloc="109" packages="1" files="7" classes="7"/>
<file name="container.tsx" path="/home/kotto/github/react-modal-global/src/container.tsx">
<metrics statements="9" coveredstatements="9" conditionals="14" coveredconditionals="14" methods="3" coveredmethods="3"/>
Expand Down
6 changes: 4 additions & 2 deletions src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ copies or substantial portions of the Software.
*/

import { ReactElement } from "react"
import { Component, ReactElement } from "react"
import { HasRequiredKeys } from "type-fest"

/**
Expand All @@ -26,7 +26,9 @@ export type ModalComponent<P = unknown> =
// Function Component
| ((props: P) => ReactElement | null)
| (() => ReactElement | null)

// Class Component
| (new (props: P) => Component)
| (new () => Component)

export interface ModalParams {
/**
Expand Down

0 comments on commit fecbf32

Please sign in to comment.