The property named 'media' cannot be omitted from <InlineTip> component, which forces the Inline Tip widget to be uncollapsable #6099
Labels
area: typescript
component: InlineTip
Sev 3
Visible or noticeable to users but does not impede functionality. Has a workaround.
type: bug 🐛
Something isn't working
Milestone
Package
Carbon for IBM Products
Description
when using in typescript code, we want the widget to be collapsable. This is controlled by the passing of the "media" property. In the InlineTip.d.ts file:
To get the collapse feature, one must not pass media, but without the ? (optional flag) the code will not compile without supplying "media=...". The fix is to add the ? to the property:
Component(s) impacted
InlineTip
Browser
Chrome, Firefox
@carbon/ibm-products (previously @carbon/ibm-cloud-cognitive) version
2.39.0
Suggested Severity
Severity 3 = The problem is visible or noticeable to users but does not impede the usability or functionality. Affects minor functionality, has a workaround.
Product/offering
IBM Storage Defender
CodeSandbox or Stackblitz example
https://carbon-for-ibm-products.netlify.app/?path=/story/experimental-onboarding-inline-tip-inlinetip--inline-tip&globals=viewport:basic
Steps to reproduce the issue (if applicable)
this is reproducible in v2.50.2
Uing the story code for InlineTip, comment out the "media: MediaType;" property.
You will see the compile-error.
Release date (if applicable)
No response
Code of Conduct
The text was updated successfully, but these errors were encountered: