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

<rh-alert>: remove deprecated toast as boolean property #1749

Closed
zeroedin opened this issue Aug 13, 2024 · 0 comments · Fixed by #1761
Closed

<rh-alert>: remove deprecated toast as boolean property #1749

zeroedin opened this issue Aug 13, 2024 · 0 comments · Fixed by #1761
Assignees

Comments

@zeroedin
Copy link
Collaborator

zeroedin commented Aug 13, 2024

Remove deprecated toast as a boolean property

/** @deprecated */
@property({ reflect: true, type: Boolean }) toast = false;

Note comments in willUpdate

willUpdate(changed: PropertyValues<this>) {
// toast as a boolean attr is deprecated, so this replicates the previous behaviour
if (changed.has('toast') && this.toast) {
this.variant = 'toast';
}
// variant as a boolean attr is deprecated, so this replicates the previous behaviour
if (changed.has('variant') && (this.variant as unknown as boolean) === false) {
this.variant = undefined;
}
}

Deprecated 14months ago

@zeroedin zeroedin self-assigned this Aug 13, 2024
@zeroedin zeroedin linked a pull request Aug 14, 2024 that will close this issue
@github-project-automation github-project-automation bot moved this from Backlog to Done ☑️ in Red Hat Design System Aug 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done ☑️
Development

Successfully merging a pull request may close this issue.

1 participant