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

Toast: Message prop is missing from ToastProps type #4568

Closed
JakeMinor opened this issue Oct 6, 2023 · 4 comments · Fixed by #4569
Closed

Toast: Message prop is missing from ToastProps type #4568

JakeMinor opened this issue Oct 6, 2023 · 4 comments · Fixed by #4569
Labels
Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible

Comments

@JakeMinor
Copy link
Contributor

JakeMinor commented Oct 6, 2023

Describe the bug

When creating a custom Passthrough object to use when setting PrimeVue to use the unstyled mode, the Message props is missing from the ToastProps type.

The message object contains the severity property which can be used for dynamic styling and is used in the premade Tailwind Passthrough object which comes as apart of PrimeVue.

Below I have attached some images to explain the issue further.

rider64_TJdvzrj8og
rider64_r8TwUYR9Va
chrome_Iv8xFW55L6

PrimeVue version

3.35.0

Vue version

3.x

Language

TypeScript

Build / Runtime

Vite

Browser(s)

Chrome

Steps to reproduce the behavior

  1. Create a custom passthrough object
  2. Add the toast property
  3. Add any of the passthrough options
  4. Attempt to access message using the following object options.props.message.severity

Expected behavior

I expect to not receive a type error when trying to dynamically change styling based on the severity of a toast.

@JakeMinor JakeMinor added the Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible label Oct 6, 2023
@JakeMinor
Copy link
Contributor Author

I am more than happy to create a PR to solve this issue if required!

@FlipWarthog
Copy link
Contributor

@JakeMinor If you can work out a PR, go for it. They're always appreciated. 🙏

@JakeMinor
Copy link
Contributor Author

JakeMinor commented Oct 6, 2023

Just finished up the PR @FlipWarthog if you have a chance to take a look :)

PR: #4569

@FlipWarthog
Copy link
Contributor

@JakeMinor Looks good to me, will need final approval from PrimeTek to merge it in. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants