Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chore/update deprecation notices #127

Merged
merged 3 commits into from
Jun 28, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions src/constants/spacing/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,21 +13,21 @@ const SPACING = {

const deprecatedProperties = {
xxsmall:
'SPACING.xxsmall is deprecated and will be removed in v3. Use SPACER.xsmall instead',
'SPACING.xxsmall is deprecated and will be removed in a future major release. Use SPACER.xsmall instead',
xsmall:
'SPACING.xsmall is deprecated and will be removed in v3. Use SPACER.small instead',
'SPACING.xsmall is deprecated and will be removed in a future major release. Use SPACER.small instead',
small:
'SPACING.small is deprecated and will be removed in v3. Use SPACER.medium instead',
'SPACING.small is deprecated and will be removed in a future major release. Use SPACER.medium instead',
base:
'SPACING.base is deprecated and will be removed in v3. Use SPACER.large instead',
'SPACING.base is deprecated and will be removed in a future major release. Use SPACER.large instead',
medium:
'SPACING.medium is deprecated and will be removed in v3. Use SPACER.xlarge instead',
'SPACING.medium is deprecated and will be removed in a future major release. Use SPACER.xlarge instead',
large:
'SPACING.large is deprecated and will be removed in v3. Use SPACER.x2large instead',
'SPACING.large is deprecated and will be removed in a future major release. Use SPACER.x2large instead',
xlarge:
'SPACING.xlarge is deprecated and will be removed in v3. Use SPACER.x4large instead',
'SPACING.xlarge is deprecated and will be removed in a future major release. Use SPACER.x4large instead',
xxlarge:
'SPACING.xxlarge is deprecated and will be removed in v3. Use SPACER.x5large instead',
'SPACING.xxlarge is deprecated and will be removed in a future major release. Use SPACER.x5large instead',
};

export default withDeprecationWarning(SPACING, deprecatedProperties);
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ const deprecatedProperties = {
const isLoadingPropFunction = (props, propName, componentName) => {
if (props[propName] !== undefined) {
return new Error(
`'loading' prop will be deprecated in the next major release. Please rename 'loading' to 'isLoading' in ${componentName}`
`'loading' prop will be deprecated in a future major release. Please rename 'loading' to 'isLoading' in ${componentName}`
);
}
};
Expand Down
2 changes: 1 addition & 1 deletion src/shared-components/button/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ const deprecatedProperties = {
const isLoadingPropFunction = (props, propName, componentName) => {
if (props[propName] !== undefined) {
return new Error(
`'loading' prop will be deprecated in the next major release. Please rename 'loading' to 'isLoading' in ${componentName}`
`'loading' prop will be deprecated in a future major release. Please rename 'loading' to 'isLoading' in ${componentName}`
);
}
};
Expand Down