Skip to content

Commit

Permalink
Removed "defaultProps" which will be deprecated.
Browse files Browse the repository at this point in the history
  • Loading branch information
evoluteur committed Mar 6, 2024
1 parent 0ce6b63 commit 58223a8
Showing 1 changed file with 5 additions and 11 deletions.
16 changes: 5 additions & 11 deletions src/Icon.js
Original file line number Diff line number Diff line change
Expand Up @@ -156,15 +156,15 @@ const svgCmp = (path, onClick, css) => (
export default function Icon({
id,
name,
size,
theme,
size = "medium",
theme = "light",
tooltip,
disabled,
disabled = false,
onClick,
className,
className = null,
color,
}) {
const path = svgPaths[name] || null;

if (!path) {
console.error('Invalid icon name "' + name + '".');
}
Expand Down Expand Up @@ -221,9 +221,3 @@ Icon.propTypes = {
className: PropTypes.string,
};

Icon.defaultProps = {
size: "medium",
theme: "light",
disabled: false,
className: null,
};

0 comments on commit 58223a8

Please sign in to comment.