-
Notifications
You must be signed in to change notification settings - Fork 81
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(button): size enum on Button, add deprecationWarning util (#229)
* feat(button): size enum on Button component Provide a size enum to eventually replace the small and big boolean props on Button re #187 * feat(Button): Add deprecation warnings, size preferred * Log deprecation warnings * Prefer size over big/small; test that interaction * Comment deprecationWarning in production * Button prop deprecation starts in v1.6.0
- Loading branch information
Showing
4 changed files
with
82 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
export const deprecationWarning = | ||
process.env.NODE_ENV !== 'production' | ||
? console.warn | ||
: () => { | ||
// do nothing in production | ||
} |