style(dashboard-v2): use PropTypes.elementType

This commit is contained in:
Michał Leszczyk 2022-02-26 12:53:12 +01:00
parent 8dcd688673
commit 4429e4e0be
No known key found for this signature in database
GPG Key ID: FA123CA8BAA2FBF4
1 changed files with 3 additions and 6 deletions

View File

@ -35,9 +35,6 @@ export const ActiveTabIndicator = ({ tabRef }) => {
); );
}; };
// Needed, because we're using an Element constant here which Gatsby doesn't recognize during build time. ActiveTabIndicator.propTypes = {
if (typeof window !== "undefined") { tabRef: PropTypes.oneOfType([PropTypes.func, PropTypes.shape({ current: PropTypes.elementType })]),
ActiveTabIndicator.propTypes = { };
tabRef: PropTypes.oneOfType([PropTypes.func, PropTypes.shape({ current: PropTypes.instanceOf(Element) })]),
};
}